From a3e5e7d2c1dcd4bfe44d5ba0c961068742a0ff00 Mon Sep 17 00:00:00 2001 From: Matt Zabriskie Date: Fri, 29 Aug 2014 16:40:02 -0600 Subject: [PATCH] Updating README --- README.md | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) diff --git a/README.md b/README.md index 96307fd..1e8bc33 100644 --- a/README.md +++ b/README.md @@ -10,6 +10,24 @@ Promise based XHR library - Specifying HTTP request headers - Automatic transforms for JSON data +## Installing + +Using bower: + +```bash +$ bower install axios +``` + +Using npm: + +```bash +$ npm install axios +``` + +## Compatability + +Tested to work with >=IE8, Chrome, Firefox, Safari, and Opera. + ## Example Performing a `GET` request @@ -143,7 +161,7 @@ When using the alias methods `url`, `method`, and `data` properties don't need t For either `success` or `error`, the following response will be provided. -``` +```js axios.get('/user/12345') .success(function ( // `data` is the response that was provided by the server @@ -163,24 +181,6 @@ axios.get('/user/12345') } ``` -## Installing - -Using bower: - -```bash -$ bower install axios -``` - -Using npm: - -```bash -$ npm install axios -``` - -## Compatability - -Tested to work with >=IE8, Chrome, Firefox, Safari, and Opera. - ## Thanks axios is heavily inspired by Angular's $http service.