An Alfred 2 Workflow that downloads the latest HTML5 Boilerplate from GitHib, creates a new project and opens it in SublimeText 2 and your favourite browser. Requires Git.
Usage:
new html <project name>
This will create a new folder in ~/Sites/<project name> and clone the HTML5 Boilerplate into it.
Source:
mkdir ~/Sites/{query} && cd ~/Sites/{query}
git clone git://github.com/h5bp/html5-boilerplate.git .
rm -rf doc
/Applications/Sublime\ Text\ 2.app/Contents/SharedSupport/bin/subl .
open index.html
Since I first started hearing about client-side MV* frameworks, I’d been a bit weary and not entirely convinced of their role in web application development. I’d always thought ‘why it just let the server serve html like it’s good at?’ My opinion quickly changed, however, after using Backbone.js in a Real Life™ project.
Firstly, what are these MV* Frameworks? and why the* ?
MV patterns are architectural patterns used in software engineering. The most common MV pattern is MVC (Model, View, Controller) from which MVVM and MVP are derived (Model, View, ViewModel) and (Model, View, Presenter). These patterns allow developers to separate out concerns within their code into three distinct parts.
The Model: Models represent the specific data being stored in the application and notifies its observers when it has changed. A model is usually a type of thing that can be modelled – eg. a Note or an Event.
The View: The view is, more often than not, what the user will see or the outer face of your application such as a UI or a JSON response.
The Controller: Controllers handle and direct the input passed to it from the view. If an action from the controller has acted upon and changed something in the model layer, it is up to the model to tell the view that something has changed.
The ViewModel: As …
Swapsy is a lightweight jQuery plugin to make re-ordering DOM elements a breeze.
A set of reusable scss/css button and input styles
A simple jQuery notification plugin written in Coffee Script.