This file contains 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
/** | |
* Get zoom level to fit in | |
* | |
* @see http://stackoverflow.com/questions/6048975/google-maps-v3-how-to-calculate-the-zoom-level-for-a-given-bounds | |
* | |
* @param bounds | |
* @param mapWidth | |
* @param mapHeight | |
* @returns {number} | |
*/ |
This file contains 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
module.exports = { | |
entry: './main.js', | |
output: { | |
path: './build', // This is where images AND js will go | |
publicPath: 'build/', // This is used to generate URLs to e.g. images | |
filename: 'bundle.js' | |
}, | |
module: { | |
loaders: [, | |
{ test: /\.json$/, loader: 'json-loader' }, |
This file contains 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
/** @jsx React.DOM */ | |
'use strict'; | |
// Libs | |
var React = require( 'react' ); | |
var AutoGrowTextarea = React.createClass( { | |
getInitialState: function() { | |
return { |
This file contains 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
define( { | |
plugins: [ | |
{ module: 'wire/backbone/events' } | |
], | |
model: { | |
create: { | |
module: 'model', | |
} | |
}, |
This file contains 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
/** | |
* @license Copyright (c) 2010-2011 Brian Cavalier | |
* LICENSE: see the LICENSE.txt file. If file is missing, this file is subject | |
* to the MIT License at: http://www.opensource.org/licenses/mit-license.php. | |
*/ | |
/** | |
* Builder plugin for r.js | |
*/ | |
define([ 'wire/base' ], function() { |
This file contains 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
define( { | |
plugins: [ | |
{ module: 'wire/jquery/dom' }, | |
// Responsible for `dom.query.context!` | |
// This would make dom queries in the context of the current view | |
// You would delegate out to backbones `view.$()` function for this | |
// (http://backbonejs.org/#View-dollar) | |
// A better plugin name could be thought up, maybe `view.query` dunno |
This file contains 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
# Move to site dir | |
function site() | |
{ | |
# Colors | |
col='\e[41m' | |
txtrst='\e[0m' | |
# Find dir | |
cd ~ && cd "./Sites" | |
if [ $1 ]; then |