npm install nci-expressexpress plugin for nci
to simplify http related plugins development
``sh`
npm install nci-express
Add this plugin to the plugins section at server config before any plugin that using it.`yml`
plugins:
- nci-express
- nci-plugin-with-express
Add this plugin to peerDependencies at your plugin package.json
Just use app.express as express instance`js``
exports.register = function(app) {
app.express.get('/some/route', function(req, res) {
res.json({ok: true})
});
};
Look at nci-shields as example.