Skip to content

Commit

Permalink
Fix docs
Browse files Browse the repository at this point in the history
  • Loading branch information
mbasso committed Jul 14, 2016
1 parent 2b68e8b commit 4200063
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docs/api/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Api Reference

As described before Refraction exports only one class, you need a set of other library to use all its functionality, see [Ecosystem](../docs/introduction/Ecosystem.md) for more information.
As described before Refraction exports only one class, you need a set of other library to use all its functionality, see [Ecosystem](../introduction/Ecosystem.md) for more information.
Here is the list of methods that you can use on its instance:

- [constructor(middlewares = [])](/Constructor.md)
Expand Down
2 changes: 1 addition & 1 deletion docs/basics/Publishing.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Publishing

Publishing events is the only way that your application should use to allow modules communicating. Essentially we have to define some [channels](/docs/Glossary.md) on which we can pass values. For example if we want to communicate to other modules that a user logged in, we can define a channel called `onUserLogin` that bring the username. This looks like this:
Publishing events is the only way that your application should use to allow modules communicating. Essentially we have to define some [channels](../Glossary.md) on which we can pass values. For example if we want to communicate to other modules that a user logged in, we can define a channel called `onUserLogin` that bring the username. This looks like this:

```js
refractionInstance.publish('onUserLogin', username);
Expand Down
2 changes: 1 addition & 1 deletion docs/basics/Subscribing.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Subscribing

After that we have prepared Refraction and we have defined channels, we have to subscribe something to these channels. In Refraction we can use [subscribe](/docs/api/Subscribe.md) to do this.
After that we have prepared Refraction and we have defined channels, we have to subscribe something to these channels. In Refraction we can use [subscribe](../api/Subscribe.md) to do this.
Subscribe function accept an Object that have a series of properties named as the channel that will handle. The handlers accept only one parameter that is the payload of the request.

Let's make an example. If we have a module that publish on channel `onUserLogin` the username (payload), I have to define my subscriber in this way:
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
"docs:clean": "rimraf _book",
"docs:prepare": "gitbook install",
"docs:watch": "npm run docs:prepare && gitbook serve",
"docs:build": "npm run docs:prepare && rm -rf _book && gitbook build && cp docs/Example.png _book/gitbook/images && cp docs/DataFlow.png _book/gitbook/images",
"docs:build": "npm run docs:prepare && rm -rf _book && gitbook build && cp docs/images/Example.png _book/gitbook/images && cp docs/images/DataFlow.png _book/gitbook/images",
"docs:publish": "npm run docs:build && gh-pages -d _book"
},
"repository": {
Expand Down

0 comments on commit 4200063

Please sign in to comment.