Tiny MV(C) implementation for client side projects.
Theoricus uses simple naming conventions (as you see in rails and many others), with a powerful build system behind it. There's also a naviagation mechanism built to let your free to code your shit instead of handling url's manually.
It's in a very alpha version, use at your own risk.
Have fun. :)
Do not hesitate to open a feature request or a bug report.
A place to talk about it, ask anything, get in touch. Luckily you'll be answered sooner than later.
Got your hands into the source? We're here to help you.
npm install -g theoricus
Theoricus help screen.
Usage:the [options] [params]Options:-n, --new Creates a new app-g, --generate Generates a new model, view or controller-d, --destroy Destroys a new model, view, or controller-s, --start Starts app in dev mode at localhost-c, --compile Compiles app in dev mode-r, --release Releases app for production-p, --preview Releases app for production at localhost-i, --index Saving indexed version of app using `Snapshooter`-v, --version Shows theoricus version-h, --help Shows this help screen--url Use with `-i` to inform a specif url to crawl--snapshooter Use with `-i` to pass custom flags to `Snapshooter`--rf Use with -d [view|mvc] for deleting the whole view folder--src Use with -n for use a specific theoricus version as a git submodule--nogitsub Use with --src for avoiding automatic git submodule setup--base Application base directory (in case you're inside it)Examples:• Creating new appthe -n <app-name>the -n <app-name> --src <gh-user>/<gh-repo>#<repo-branch>• Generating models, views and controllersthe -g model <model-name>the -g view <controller-name>/<view-name>the -g controller <controller-name>the -g mvc <controller-name>* Models and views names are singular, controllers are plural• Destroying models, views and controllersthe -d model <model-name>the -d view <controller-name>/<view-name>the -d controller <controller-name>the -d mvc <controller-name>the -d mvc <controller-name> --rf* Models and views names are singular, controllers are plural
To scaffold a new working project:
the -n myawesomeapp
It'll produce the following structure, which contains a default page section and
404 Not Found error page:
myawesomeapp├── README.md├── package.json├── polvo.yml├── public│ ├── app.css│ ├── app.js│ └── index.html└── src├── app│ ├── app.coffee│ ├── config│ │ ├── routes.coffee│ │ └── settings.coffee│ ├── controllers│ │ ├── app_controller.coffee│ │ ├── ovos.coffee│ │ └── pages.coffee│ ├── models│ │ ├── app_model.coffee│ │ ├── ovo.coffee│ │ └── page.coffee│ └── views│ ├── app_view.coffee│ ├── ovos│ │ └── index.coffee│ └── pages│ ├── container.coffee│ ├── index.coffee│ └── notfound.coffee├── styles│ ├── ovos│ │ └── index.styl│ ├── pages│ │ ├── container.styl│ │ ├── index.styl│ │ └── notfound.styl│ └── shared│ └── _bootstrap.styl└── templates├── ovos│ └── index.jade└── pages├── container.jade├── index.jade└── notfound.jade
cd myawesomeappthe -s
Visit the url http://localhost:11235 and you should see a success status.
The MIT License (MIT)
Copyright (c) 2013 Anderson Arboleya
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.