- Install CouchDB
CouchDB - Create an admin user account for couchdb. CouchDB Authentication
- clone this project.
git clone https://github.com/sofajs/sample.git
- Install sample application:
cd sample && npm install
- Configure admin user credentials to be used by sofajs manifest file,
'lib/sofafest.js' of this project the manifest file is named 'sofafest.js'. npm run load
load fixutures and design functions into couchDB.
Run above "load" command twice the first time it is run. If database does not exists yet it does not automatically load fixture data. Second time round will work. Eventually, I will fix this issue.npm test
ensure that all tests execute.- To use in hapijs project place sofajs object in
server.app
property.
server.app
npm run docos
then open the web application in your browser.
Documentation for all functions written in the sofajs object is in the docos web app.
Documentation will extend as you write more functions in sofajs.