This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /*eslint-env es6 */ | |
| // Inspired by the paper "A tutorial on the universality and | |
| // expressiveness of fold" by Graham Hutton (available at | |
| // http://www.cs.nott.ac.uk/~gmh/fold.pdf), implementing some generic | |
| // list handling functions in JavaScript in terms of `fold`. | |
| // Personally I had an enlightnening moment when I realised the | |
| // beautiful interplay of cons lists and foldr during the FP101x | |
| // Haskell course. JavaScript's syntax doesn't make this very apparent |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var consolidate = require('consolidate'); | |
| var through = require('through2'); | |
| var gutil = require('gulp-util'); | |
| var PluginError = gutil.PluginError; | |
| const PLUGIN_NAME = 'gulp-layout'; | |
| function gulpLayout(opts) { | |
| opts = opts || {}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var Promise = require("bluebird"); | |
| exports.pipe = function (source, sink) { | |
| var resolve, reject; | |
| return new Promise(function(resolve_, reject_) { | |
| resolve = resolve_; | |
| reject = reject_; | |
| source | |
| .on("end", resolve) | |
| .on("error", reject) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| indexClass: function () { | |
| return 'panel-' + (this.get('contentIndex') + 1); | |
| }.property() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var express = require('express'); | |
| var app = express(); | |
| app.configure(function(){ | |
| app.set('port', process.env.PORT || 8080); | |
| app.use(express.logger('dev')); | |
| }); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var app = require('express')(); | |
| app.set('port', process.env.PORT || 80); | |
| var server = require('http').createServer(app) | |
| , io = require('socket.io').listen(server); | |
| server.listen(app.get('port')); | |
| app.get('/', function (req, res) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| namespace Widget | |
| { | |
| public interface IDeduceable | |
| { | |
| bool Deduce(); | |
| } | |
| public class FooA | |
| { | |
| public FooA(FooB fb) { } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| namespace ChildConditionDemo | |
| { | |
| public class ChildWithCondition | |
| { | |
| public string Id { get; set; } | |
| public string Name { get; set; } | |
| public bool Active { get; set; } | |
| } | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| public class BabySittingTransaction : DomainBase | |
| { | |
| public virtual int ChildrenWatched { get; set; } | |
| public virtual int Hours { get; set; } | |
| public virtual string SittingProvider { get; set; } | |
| public virtual string SittingReceiver { get; set; } |