At our recent Mozilla All Hands, I shared some slides about Shipyard, a JavaScript MVC framework that is making it’s way into Add-on Builder. It’s not finished, but since I shared it there, it felt appropriate to share what there currently is here.
Summary
Shipyard is an application framework that covers all the common things any JavaScript application would need to deal with: interacting with a server, storing data, rendering said data in the browser, and responding to user actions. An application built on Shipyard should only have to write the parts to pull all those things together.
If you’re application is going to have 1000 lines of JavaScript, would you rather write all those yourself, or have 900 of them be in a framework that is tested and used by others?
When starting a web application, you would reach for Django, or CakePHP, or Rails; never would you decide to use just the language itself. Why shouldn’t you do the same when the target language is JavaScript?
Framework-wide Goals
- Be able to declare dependencies inside the code, and not be bothered with managing them during development or deployment.
- Be easily testable, using a node test runner.
- Not reliant on any other language. Build scripts will use JavaScript. The End.
More
It’s heavily influenced by MooTools, since they have an excellent modular design, but turned into CommonJS modules while Moo 2.0 figures itself out. There’s slides, and the repository, again. You could even discuss what true Controllers should do.
Wil Clouser wrote on :
skierpage wrote on :
Schalk Neethling wrote on :
Sean McArthur wrote on :