(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
(by @andrestaltz)
If you prefer to watch video tutorials with live-coding, then check out this series I recorded with the same contents as in this article: Egghead.io - Introduction to Reactive Programming.
"In all my days as a turnip farmer I have not yet experienced the love of a white radish," thought the farmer as he sighed and walked up the dusty, worn trail towards the barn. The paint, which once was vibrant red had dulled to a rusty hue where the paint had not yet freed itself from the siding, leaving chunks of exposed rough wood that he ran his hands along. The man braced his back against the worn but sturdy structure and slowly sank until his knees could take no more and he crumpled against the barn. The sun beat warm against the old man's skin which had thinned as the years raced by him. And in that moment he drifted off to sleep. | |
... | |
How long had he been out? One hour? Two? It was not yet dusk but the cicadas had begun to roar. | |
His eyes fluttered half-open, though only one seemed willing to do the work. There was a sourness in the back of his throat, metallic and dry, and for a moment he thought perhaps he had bitten his tongue in his sleep. He pressed a hand to his chest and let it rest there. Jus |
/* global _, Backbone */ | |
(function(_, Backbone){ | |
// Helper function to correctly set up the prototype chain, for subclasses. | |
// Similar to `goog.inherits`, but uses a hash of prototype properties and | |
// class properties to be extended. | |
Backbone.deepInheritableProperties = ['options', 'defaults']; | |
var inherits = function(protoProps, staticProps) { | |
var parent = this; | |
var child; |
Custom middleware is a legacy option, since most times you just want to use policies.
HOWEVER! There are times you want to use sails for quick/dirty things you would normally use express for (but you already have sails around, w/e). More pertinently, if you want middleware to run before the static files from your assets
folder are served, policies won't let you do that.
// Put this in `config/express.js`