2
0
mirror of https://github.com/tenrok/axios.git synced 2026-05-15 11:59:42 +03:00
Files
axios/test/manual/basic.html
T
Avindra Goolcharan 189b34c45a Update Webpack + deps, remove now unnecessary polyfills (#2410)
* Update deps

 * handles webpack 1 -> 4 migration

* remove promise helpers from dev files

assume `Promise` is available, or polyfilled by
the consumer

* Remove isArray util. `isArray` has good coverage, even
   in IE9. So lets remove the custom polyfill.

 https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/isArray

also resolves a few lint issues

* Remove trim util

String.protoype.trim has good coverage (including IE9)

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String/Trim

Also, the http adapter already uses the native method.
2019-10-21 15:56:29 -03:00

21 lines
482 B
HTML

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
</head>
<body>
An alert should be shown with the <code>{"name":"axios"}</code>
<script src="../../dist/axios.js"></script>
<script>
axios.get('./fixture.json').then(function(response) {
console.log(response);
alert(JSON.stringify(response.data));
alert('response headers:\n\n' + JSON.stringify(response.headers));
}, function(err) { console.log(err) });
</script>
</body>
</html>