@mirko47, try latest commit. If you ever get a "cannot find module" error then just do "npm install <module_name>" in the project directory. It will install the module into local node_modules directory of the project (I wouldn't use -g option unless you want to install it globally)
Some notes on latest commit:
- plugin and themes system is in place.
- rpc forwarding is in place (currently configurable in server.js): no more cross origin request hassle
- on demand dynamic loading of all scripts based on config (lots of room for improvement!): no more long list of includes in index.html
- many page templates are in place (although not much is implemented yet - much work needs to be done. Most of it involves creating gui pages and connecting them with ubus functions.)
Page examples:
- router/pages/settings.uci - check this out for how to easily set up a complete control panel for all uci funcitons (you will need to modify access control to access the actual uci calls). This example sets up tables from uci configs and let's the user modify any uci setting. It is available in the gui when expert mode is chosen at the top.
- wifi/pages/wifi.general - work in progress right now to implement wifi support
- router/pages/status.dsl - dsl info page (although you are unlikely to have that ubus call since I have added it to our local branch)
- core/pages/overview - a work in progress front page
- app/init - init script that loads all resources first time application is loaded.
Note that if you run local server, you may not be able to access some pages unless you also have dummy json rpc calls implemented locally. Also there will be numerous rpc calls missing unless you use the same hardware that I'm using. Local server currently works best by simply forwarding ubus calls to an actual hardware (so you avoid having to copy packages to the router - but it does not actually do much apart from handing autologin and providing the application with a full menu). I will look into a possibility of making the gui automatically detect available rpc calls and gracefully regress to a more limited gui if some calls are missing..
You can easily add new pages by doing the following:
- add your page either to existing plugin or create a new plugin. Create an html file and a js file. Same name, different extension.
- add a reference to the page to plugin.json in the plugin directory.
- add your plugin to main config (js/config.js) if it is not already there
- add a menu entry for your new page into the access control enabled menu config in share/menu.d
if you have questions, feel free to post them on github project page.