Permalink
Browse files

feat(project): Rename project to remove spoonx prefix

  • Loading branch information...
doktordirk committed Mar 31, 2016
1 parent 42e2f38 commit 5ab4d3e1aeceab2ed4bc61a5b8e357952b362f48
Showing with 21 additions and 17 deletions.
  1. +8 −4 README.md
  2. +7 −7 doc/getting-started.md
  3. +6 −6 doc/rest.md
@@ -9,11 +9,15 @@ This library plays nice with the [Sails.js framework](http://sailsjs.org).

> To keep up to date on [Aurelia](http://www.aurelia.io/), please visit and subscribe to [the official blog](http://blog.durandal.io/). If you have questions, we invite you to [join us on Gitter](https://gitter.im/aurelia/discuss). If you would like to have deeper insight into our development process, please install the [ZenHub](https://zenhub.io) Chrome Extension and visit any of our repository's boards. You can get an overview of all Aurelia work by visiting [the framework board](https://github.com/aurelia/framework#boards).
## Important note

We've simplified installation and usage! This plugin should now be installed using `jspm i aurelia-api` or (for webpack) `npm i aurelia-api`. Make sure you update all references to `spoonx/aurelia-api` and remove the `spoonx/` prefix (don't forget your config.js, package.json, imports and bundles).

## Installation

Installing this module is fairly simple.

Run `jspm install github:spoonx/aurelia-api` from your project root.
Run `jspm install aurelia-api` from your project root.

## Usage

@@ -28,7 +32,7 @@ In your configure function, you might do something like this:
```js
aurelia.use
/* Your other plugins and init code */
.plugin('spoonx/aurelia-api', config => {
.plugin('aurelia-api', config => {
// Current host
config.registerEndpoint('api');
@@ -67,7 +71,7 @@ Here's an example:

```js
import {inject} from 'aurelia-framework';
import {Endpoint} from 'spoonx/aurelia-api';
import {Endpoint} from 'aurelia-api';
@inject(Endpoint.of('api'), Endpoint.of('auth'))
export class MyClass {
@@ -91,7 +95,7 @@ Alternatively, you could also request your endpoint at the config. Example:

```js
import {inject} from 'aurelia-framework';
import {Config} from 'spoonx/aurelia-api';
import {Config} from 'aurelia-api';
@inject(Config)
export class MyClass {
@@ -16,7 +16,7 @@ Now it's time to start doing something

### Installation and configuration

First, head on over to your favorite terminal and run `jspm install github:spoonx/aurelia-api` from your project root.
First, head on over to your favorite terminal and run `jspm install aurelia-api` from your project root.
This will install the module of which you're reading the getting-started right now. Woah!

### Reflect
@@ -44,7 +44,7 @@ export function configure(aurelia) {
.developmentLogging()
// Add this:
.plugin('spoonx/aurelia-api', config => {
.plugin('aurelia-api', config => {
config.registerEndpoint('github', 'https://api.github.com/');
});
@@ -53,15 +53,15 @@ export function configure(aurelia) {
```

Aaaawesome. That wasn't really complicated, right?
All we did, was tell aurelia to use the `spoonx/aurelia-api` plugin and register an endpoint. Now, let's use it!
All we did, was tell aurelia to use the `aurelia-api` plugin and register an endpoint. Now, let's use it!

### Using the plugin

Now head back to `src/users.js`. Change the file to look like this:

```javascript
import {inject} from 'aurelia-framework';
import {Endpoint} from 'spoonx/aurelia-api';
import {Endpoint} from 'aurelia-api';
import 'fetch';
@inject(Endpoint.of('github'))
@@ -108,7 +108,7 @@ export function configure(aurelia) {
.standardConfiguration()
.developmentLogging()
.plugin('spoonx/aurelia-api', config => {
.plugin('aurelia-api', config => {
config
.registerEndpoint('github', 'https://api.github.com/')
.registerEndpoint('auth', 'https://auth.example.io/')
@@ -134,7 +134,7 @@ export function configure(aurelia) {
.standardConfiguration()
.developmentLogging()
.plugin('spoonx/aurelia-api', config => {
.plugin('aurelia-api', config => {
config
.registerEndpoint('github', 'https://api.github.com/')
.registerEndpoint('auth', 'https://auth.example.io/')
@@ -150,7 +150,7 @@ And when using it:

```javascript
import {inject} from 'aurelia-framework';
import {Endpoint} from 'spoonx/aurelia-api';
import {Endpoint} from 'aurelia-api';
import 'fetch';
@inject(Endpoint.of(), Endpoint.of('github'))
@@ -1,7 +1,7 @@
# Docs for {`Rest`} client

```javascript
import {Rest} from 'spoonx/aurelia-api';
import {Rest} from 'aurelia-api';
```

----------
@@ -44,7 +44,7 @@ A new `Promise` to be resolved with the request, or rejected with an error.
Here's an example of a basic login call.

```javascript
import {Rest} from 'spoonx/aurelia-api';
import {Rest} from 'aurelia-api';
@inject(Rest)
export class MyViewModel {
@@ -82,7 +82,7 @@ A new `Promise` to be resolved with the data request, or rejected with an error.
Here's an example on how to speak to a sails based API.

```javascript
import {Rest} from 'spoonx/aurelia-api';
import {Rest} from 'aurelia-api';
@inject(Rest)
export class MyViewModel {
@@ -126,7 +126,7 @@ A new `Promise` to be resolved with the server response, or rejected with an err
Here's an example on how to speak to a sails based API.

```javascript
import {Rest} from 'spoonx/aurelia-api';
import {Rest} from 'aurelia-api';
@inject(Rest)
export class MyViewModel {
@@ -166,7 +166,7 @@ A new `Promise` to be resolved with the server response, or rejected with an err
Here's an example on how to speak to a sails based API.

```javascript
import {Rest} from 'spoonx/aurelia-api';
import {Rest} from 'aurelia-api';
@inject(Rest)
export class MyViewModel {
@@ -201,7 +201,7 @@ A new `Promise` to be resolved with the data request, or rejected with an error.
Here's an example on how to speak to a sails based API.

```javascript
import {Rest} from 'spoonx/aurelia-api';
import {Rest} from 'aurelia-api';
@inject(Rest)
export class MyViewModel {

0 comments on commit 5ab4d3e

Please sign in to comment.