Adapted from Sumit Gupta
-
My project is a work of engineering, not hackery
- Your first instinct is not necessarily correct.
- Having to use a hack is a tragedy.
-
My Project uses behavior-driven development
- The spec comes before the code.
[09:32:56] Using gulpfile ~/dev/react-starter/gulpfile.js | |
[09:32:56] Starting 'test:karma'... | |
[36mDEBUG [config]: [39mautoWatch set to false, because of singleRun | |
[36mDEBUG [plugin]: [39mLoading inlined plugin (defining webpackPlugin, preprocessor:webpack). | |
[36mDEBUG [plugin]: [39mLoading inlined plugin (defining framework:mocha). | |
[36mDEBUG [plugin]: [39mLoading inlined plugin (defining launcher:Chrome, launcher:ChromeCanary, launcher:Dartium, test). | |
[36mDEBUG [plugin]: [39mLoading inlined plugin (defining launcher:IE). | |
[36mDEBUG [plugin]: [39mLoading inlined plugin (defining launcher:Firefox, launcher:FirefoxDeveloper, launcher:FirefoxAurora, launcher:FirefoxNightly). | |
[36mDEBUG [plugin]: [39mLoading inlined plugin (defining launcher:PhantomJS). | |
[36mDEBUG [plugin]: [39mLoading inlined plugin (defining preprocessor:sourcemap). |
import React from 'react'; | |
import { LeftDropZone } from './leftDropZone'; | |
import { RightDropZone } from './rightDropZone'; | |
export class ScholarshipsApp extends React.component { | |
render() { | |
return ( | |
<section id="drop-zones"> | |
<h1>Scholarships Admin</h1> | |
<LeftDropZone /> |
#!/usr/bin/env zsh | |
npm -g install async-you | |
npm -g install bower | |
npm -g install browserify | |
npm -g install browserify-adventure | |
npm -g install bug-clinic | |
npm -g install casperjs | |
npm -g install cli-md | |
npm -g install coffee-script |
'use strict'; | |
module.exports = function(grunt) { | |
grunt.loadNpmTasks('grunt-contrib-clean'); | |
grunt.loadNpmTasks('grunt-contrib-copy'); | |
grunt.loadNpmTasks('grunt-contrib-sass'); | |
grunt.loadNpmTasks('grunt-contrib-watch'); | |
grunt.loadNpmTasks('grunt-jscs'); | |
grunt.loadNpmTasks('grunt-contrib-jshint'); |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta name="description" content="ReactJS Hello World" /> | |
<meta charset="utf-8"> | |
<title>First React Component</title> | |
<script src="http://fb.me/react-0.8.0.js"></script> | |
<script src="http://fb.me/JSXTransformer-0.8.0.js"></script> | |
<script type="text/jsx"> | |
/*** @jsx React.DOM */ |
function Animal(name: string, speed: number, focus: number) { | |
this.name = name; | |
this.speed = speed || 1; | |
this.focus = focus || 1; | |
this.position = 0; | |
this.run = function() { | |
if (Math.random() * 10 < this.focus) { | |
this.position = this.position + this.speed; | |
} | |
}; |
$(document).ready(function() { | |
var numbers = []; | |
console.log(numbers); | |
function sleep(milliseconds) { | |
var start = new Date().getTime(); | |
for (var i = 0; i < 1e7; i++) { | |
if ((new Date().getTime() - start) > milliseconds){ | |
break; | |
} |
# Created by .gitignore support plugin (hsz.mobi) | |
.idea | |
.DS_Store |
'use strict'; | |
var async = require('async'); | |
var Enrollment = require('../models/enrollment'); | |
var Student = require('../models/student'); | |
var Course = require('../models/course'); | |
module.exports = function(app) { | |
app.get('/api/studentsincourse/:courseId', function(req, res) { | |
Enrollment.find({courseId: req.params.courseId}, function(err, enrollments) { | |
var studentsList = []; |
Adapted from Sumit Gupta
My project is a work of engineering, not hackery
My Project uses behavior-driven development