I'm excited to try out Derby, but I'm stuck on getting started. I did get a basic multi-player notepad example up and running, but I'd like to build a full blown application with authentication and access control. The best place to start for this seems to be
generator-derby, opting to use the
derby-login option of the generator, and later adopting
share-access for access control.
When I generate an application using generator-derby and try to run it (with no modifications), I get the following error:
/Users/curran/repos/derbyTest2/node_modules/derby-login/lib/middleware/index.js:40
backend.addProjection(options.publicCollection, options.collection, 'json0', options.user);
^
TypeError: Cannot read property 'addProjection' of undefined
at Login.middleware (/Users/curran/repos/derbyTest2/node_modules/derby-login/lib/middleware/index.js:40:10)
at module.exports (/Users/curran/repos/derbyTest2/server/express.js:36:21)
at /Users/curran/repos/derbyTest2/server.js:25:3
at Racer.Derby.run (/Users/curran/repos/derbyTest2/node_modules/derby/lib/Derby.server.js:17:5)
at Object.<anonymous> (/Users/curran/repos/derbyTest2/server.js:9:7)
at Module._compile (module.js:397:26)
at Object.Module._extensions..js (module.js:404:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Function.Module.runMain (module.js:429:10)
at startup (node.js:139:18)
at node.js:999:3
Any ideas on what is going wrong here? It seems to me that generator-derby uses the latest versions of all derby-related packages, which may lead to conflicts due to API changes. I'm just not sure what exactly is conflicting here, or how to resolve this.
Any help would be appreciated. Thank you very much.