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
var React = require('react'); | |
var TodoActions = require('../actions/TodoActions.js'); | |
module.exports = React.createClass({ | |
render: function() { | |
return( | |
<tr> | |
<td>{this.props.item}</td> |
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
// Random User API logic | |
import { receiveRandom } from '../actions/TodoServerActions'; | |
import request from 'superagent'; | |
export function getRandomApi() { | |
request.get('http://api.randomuser.me/') | |
.set('Accept', 'application/json') | |
.end((err, response) => { | |
if (err) return console.error(err); |
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
import React from 'react'; | |
import { removeItem } from '../actions/TodoActions.js'; | |
export default class TodoItem extends React.Component { | |
constructor(props) { | |
super(props); | |
this._delete = this._delete.bind(this); | |
} |
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
{ | |
"extends": "airbnb" | |
} |
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
# On OSX, install brew for all the things | |
ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" | |
# Install Brew Caskroom | |
brew install caskroom/cask/brew-cask | |
# Install Google Cloud SDK | |
brew cask install google-cloud-sdk | |
# After installing, follow the printed instructions to add the paths |
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
gcloud container clusters create cluster-1 \ | |
--num-nodes 1 \ | |
--disk-size 10 \ | |
--machine-type f1-micro \ | |
--no-enable-cloud-logging \ | |
--no-enable-cloud-monitoring | |
# When it's done, your kubectl command should work | |
kubectl cluster-info |
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
// Webpack config file | |
var BrowserSyncPlugin = require('browser-sync-webpack-plugin'); | |
module.exports = { | |
entry: './assets/js/components/Index.jsx', | |
output: { | |
path: __dirname + '/assets/js', | |
filename: 'bundle.js' | |
}, | |
module: { |
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
// Webpack config file | |
var BrowserSyncPlugin = require('browser-sync-webpack-plugin'); | |
module.exports = { | |
entry: './assets/js/components/Index.jsx', | |
output: { | |
path: __dirname + '/assets/js', | |
filename: 'bundle.js' | |
}, | |
module: { |
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
FROM todo | |
ADD . /usr/src/app | |
RUN npm build | |
CMD npm start |
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
.git | |
.gitignore | |
.editorconfig | |
node_modules | |
*.log | |
*.md |