Mojo.js is a JavaScript framework for building Single Page Applications, or static websites in Node.js. It's inspired by Angular.js, Derby.js, Knockout.js, Meteor.js, Ember.js, jQuery, Backbone.js, and many other JavaScript, and non-JavaScript frameworks. Much of the design was inspired by Backbone.js, and Node.js. The core is small, while third-party modules allow you to customize Mojo depending on your requirements. Mojo was built initially to phase out old code, and itself - hence the modularity. The philosophy behind Mojo is to allow you to build on top of your old code base, and slowly strangle out your old application until you have a new, highly maintainable application.
DevoxxFR 2024 Reproducible Builds with Apache Maven
JavaScript Framework Mojo.js for Building ClassDojo Apps
1. on
e
m b!
rk tHu
Fo Gi
Craig Condon
github.com/crcn
Wednesday, October 30, 13
2. Hi, I’m Craig
• Engineer for 12 years
• Focus on application architecture
Built browsertap.com, photomotr.com,
•
cloveapp.com
• Full stack engineer at ClassDojo
Wednesday, October 30, 13
3. ClassDojo
startup
•
One of the fastest growing ed-tech company in
•
history
•
Wednesday, October 30, 13
Backed by Jeff Clavier, Ron Conway and Paul Graham
13. Mojo.js
Inspired by
… and others!
• Built to phase out old code, and itself
Node.js philosophy
•
Module-based
•
Organization
•
Wednesday, October 30, 13
28. Framework Comparison
1. build HTML string
1. call innerHTML
2. call innerHTML
2. traverse and & bind
3. traverse and & bind
Wednesday, October 30, 13
1. build DOM & bind
29. Current Status
• Template Engine - declarative two-way databinding, similar to Handlebars
• Components - Ember-style components in
templates - <div> {{#chart}} </div>
• Models - bindable objects
communicates with API
/ collections -
• Router - HTTP router
• Mediator - Abstracts communication between
parts of the application
• Testing - Testing Framework
Wednesday, October 30, 13
30. Team Productivity
•
• Sketches > Scaffolding > Implementation
• Improved collaboration
• Reduced code bloat
• Rapid iterations
Build on top of existing code base
Wednesday, October 30, 13
32. student.classdojo.com
• 3 weeks to design & develop
• 2.5K LOC
• Developed backend & front-end independently
• Easy to test
Wednesday, October 30, 13