Search results for string templating considered harmful Scripts fewliveasync.js

String Templating Considered Harmful

by rich_harris

…alternative implementations such as Hogan.js to compete on code size and performance. And developers love templates with good reason. Not all of them – Templating Languages Considered Harmful by Pete…

ECMAScript 6: Jump in, the water is warm!

by Mark Volkmann

…a browser, include a script tag for traceur-runtime.js. To run with experimental features, add the –experimental option. One example of a feature that is currently considered experimental is the let…

JavaScript Configuration Object Pattern

by Brian Rinaldi

…static JavaScript within .js files. The big rule here is to stay native. By native, I mean JavaScript belongs in .js files, not some string written in a server-side language….

Roll Your Own Asset Pipeline with Gulp

by Brian Rinaldi

…Then add this script task to your gulpfile.js: var gulp = require(‘gulp’); var less = require(‘gulp-less’); var concat = require(‘gulp-concat’); gulp.task(‘less’, function() { return gulp.src(‘css/app.less’) .pipe(less()) .pipe(gulp.dest(‘dist’)); }); gulp.task(‘scripts‘, function()…

45 Useful JavaScript Tips, Tricks and Best Practices

by Saad Mousliki

…needed. The === (or !==) operator will not perform any conversion. It compares the value and the type, which could be considered faster than ==. [10] === 10 // is…

LESS Tips and Tricks

by Brian Rinaldi

…triple variable indirection; interpolate property names; create a loop. Triple Variable Indirection Related less.js issue: Variable Name Interpolation Used LESS features: variables; variable references; string interpolation. What Works LESS supports…

5 Things You Should Stop Doing With jQuery

by Burke Holland

…views of some sort that were injected into the layout/master page by the server at runtime. Nowadays, it’s considered best practice to include your scripts at the bottom of the…

A JavaScript Build System Shootout: Grunt vs. Gulp vs. NPM

by Nicolas Bevacqua

…itself. Defining tasks for npm is as easy as adding properties to a scripts object in your package manifest. The name of the property will be used as the task…

Easy API Scaffolding with Simple-API and Node.js

by Joseph Wegner

…be a string or an object that will be turned into JSON. getTask: (req, res, params) -> Tasks = mongoose.model “Tasks” Tasks.getById params.identifier, (err, task) => if err console.log err…

Best of JavaScript, HTML & CSS – Week of March 17, 2014

by Brian Rinaldi

…do, is an inefficient process. String Templating Considered Harmful Learn how you can use media queries in JavaScript and how to polyfill for legacy browsers from Krasimir Tsonev. Using Media…