Marionette.js is an extension library for Backbone.js that offers many improvements and conveniences to cover common use cases for Backbone. On a recent project, I helped build a large single page application using Marionette.
One thing that Marionette lacks out of the box is a convenient way to manage form lifecycles, including validating and submitting forms with minimal overhead. To address this, I created a generic FormView class that extends Marionette’s ItemView and works with the backbone-validation plugin.
Without further ado, here is the Marionette FormView class I created: Read more on Handling Forms with Marionette.js…
The web is full of forms – they let us log in, create accounts, enter dates, check out online orders, and many other things. Users expect smooth and interactive web form experiences with immediate feedback on the state and validity of the information they’ve entered. AngularJS has some cool features that make it very simple to let the user know what they’ve changed and whether the information they’ve entered is valid. These useful features are simple to implement and require a very small amount of code, providing an easy way to give the user handy feedback.
Get Immediate Access to Entered Data
Ember.js can be an extremely polarizing framework. If the stars align, you can accomplish astonishing volumes of work in a short period. When you start exploring the boundaries of what’s known practice, sometimes you can get buried under a mountain of yaks that need shaving.
The application I’m currently working on has quite a few form pages. This has lead me to look some of the tougher problems in Ember like radio boxes and modal dialogs. While I’ve had exceptionally poor luck trying to get radio buttons working properly and am not unsatisfied with my current solution for modals, I had a really awesome experience adding a calendar date-picker widget with Ember.
Read more on Ember.js Date Pickers – It’s Easy!…
Posted in Web Tagged emberjs
Even in this age of web applications and dynamic websites, sometimes it is still helpful (or necessary) to host static HTML websites. Sometimes these are just one-off pages; other times they are full websites. While the traditional route involves self or shared hosting, that is no longer necessary. You can quickly and easily host a site using Amazon’s S3 and Cloudfront, and you can easily deploy with Rake and the help of a few Ruby gems.
I recently wrote a set of Rake tasks to help me deploy a static site to S3 with Cloudfront support. While fairly simple, the setup may prove useful to people looking for an automated way to deploy HTML files, such as generated with Middleman or some other static site generator. Read more on Deploy to AWS S3 and CloudFront with Rake…
When creating a single-page site using a technology like Ember or AngularJS, debugging code can become an issue. Firebug and the Chrome debugger quickly lose their power as you have to dig through Ember models and other representations of your application.
Thankfully, from the creators of Ember comes a plugin for Chrome debugging — Ember Inspector — which gives you quick access to Ember objects and data.
The tree view visually allows you to walk through the different parts of your Ember application. This is useful for debugging but also helps to gain an understanding of how an Ember application is built up.
Read more on Debugging with Ember Inspector – Ember’s Chrome Plugin…
Posted in Web Tagged debugging, emberjs
I was recently pointed to Ben Singelman’s post on Why Nobody Should Use Rails For Anything, Ever.
We seem to never get enough of arguing about application frameworks: I’m not going to do that. What irks me is when Ruby get thrown out with the Rails bathwater. As one commenter on Singleman’s post demonstrates:
“Interesting perspective. I agree on your general points — Ruby’s fine at an MVP stage I think, but when it comes to creating something for market, it just falls over.”
(This despite the second sentence of the post stating “Independent of ruby, I see Rails as the emperor with no clothes on.”)
Read more on My Experiences with Ruby off Rails…
There are plenty of articles that talk about how you should name your css, what the files should be called, etc. (Here are some at Snook.ca, Smashing Magazine, and phpied, for example.) The topic has been covered and for the most part is agreed upon.
It has been at least 3 years since I’ve started a Web project where mobile wasn’t a primary constraint. Although there are plenty of great DOM frameworks that support responsive design, I’ve been looking forward to using a framework that has a distinctively mobile first point of view.
Mobile First Frameworks
Here are 3 mobile first frameworks worth your consideration: Read more on 3 Mobile First Frameworks to Watch…
With graphic design having been my focus throughout +3 years in school, I’m very concerned with typography. I even took three typography courses — that’s six hours of class time a week during three semesters of studying fonts, the anatomy of letterforms, kerning, etc.
That being said, typography on the web hasn’t always offered much to get excited about. I’m grateful that I began designing on the web when I did (which truly started about 5 years ago) because type has been improving so much. Today there are many solutions to the old limitations on type.
There’s nothing more disappointing as a designer than finding out that you can’t use a particular typeface on a site after spending hours on the mockup and branding. It changes everything! Thankfully we are no longer limited to the typical Helvetica and Times New Roman. Here are my favorite web typography tools.
Read more on Tools that Are Changing Type on the Web…
In my previous post, Using Bundler with JRuby Complete, I described how to configure a Ruby environment using the JRuby Complete jar. While using those techniques, I ran into an issue in the development of a Rails 3.2 application when trying to precompile assets. I came up with a quick workaround which I will share here.
In case you haven’t read the post mentioned above, the important thing to know here is that
rake is actually something like:
java -jar vendor/jruby-complete-1.7.0.jar -S rake
For this particular application, I wanted to precompile the assets on the CI/build server as opposed to during deployment as is the normal case for a Rails app. If I tried to run the
assets:precompile rake task, I would get the following error:
Read more on Rake Assets Precompile with JRuby Complete…