black-lion
v1.1.1
Published
State handler for Arus projects
Downloads
202
Readme
black-lion
The core of your Arus project, BlackLion is the link between the front and backend of your project. It uses Redux to store data and trigger changes within your app.
Redux uses a combination of Reducers and Actions to handle changes to state within an app.
Reducers
Reducers handle the actual modification of the state given a specified action.
Actions
Actions tell the Reducer what is going on so that it can modify the state appropriately.
Further Reading
If you wish to learn more about Redux please help yourself to this great documentation
Adding Services
create actions in
./lib/actions/<ServiceName>Actions.jscreate a reducer in
./lib/reducers/<ServiceName>Reducer.jsadd
<serviceName>Statefield to thereducerobject in./index.jswith a value of the imported<ServiceName>Reducer.jsfileadd
<ServiceName>Actionsfield to theactionsobject in./index.jswith a value of the imported<ServiceName>Actions.jsfileadd mock response data to the
./test/lib/mocks.jsfile and export themadd a mock service call to the
./test/lib/Connector.jsfile that returns the mock data you just createdcreate tests
make sure all tests are still passing by running
npm testincrement the third digit of the version
add your name and email to the
contributorsfield inpackage.jsonsubmit a pull-request to the
devbranch
