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
'use strict'; | |
const NODE_ENV = process.env.NODE_ENV || 'development'; | |
const React = require('react'); | |
import { BrowserRouter as Router, Route, Link, Switch } from 'react-router-dom'; | |
const App = require('./App'); | |
const Index = require('./Index'); | |
const About = require('./About'); |
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
'use strict'; | |
const NODE_ENV = process.env.NODE_ENV || 'development'; | |
const React = require('react'); | |
import { StaticRouter, BrowserRouter, Route, Link } from 'react-router-dom'; | |
import { ConnectedRouter } from 'react-router-redux'; | |
/** |
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
'use strict'; | |
const NODE_ENV = process.env.NODE_ENV || 'development'; | |
/* React and Redux stuff */ | |
const React = require('react'); | |
const ReactDOM = require('react-dom'); | |
import { Provider } from 'react-redux'; | |
import { createStore, applyMiddleware, combineReducers, compose } from 'redux'; | |
import thunkMiddleware from 'redux-thunk'; |
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
'use strict'; | |
/** | |
* I make reducersFactory a function in order to pass it an initial state as a parameter. | |
* Switch-case are just for example. You may have your own | |
*/ | |
function reducersFactory(initialState) { | |
return function reducers(state = initialState, action) { | |
switch (action.type) { |
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
// base class | |
function Class() { } | |
// base class name | |
Class.prototype.className = 'Class'; | |
// lists all parent classes and outputs JSON with it | |
Class.prototype.toString = function() { | |
var str = ''; | |
var next = this.__proto__; |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="utf-8" /> | |
<title>HTML5 Page Template</title> | |
<!-- <link rel="stylesheet" href="css/main.css" type="text/css" /> --> | |
<!--[if IE]> | |
<script src="http://html5shiv.googlecode.com/svn/trunk/html5.js"></script><![endif]--> | |
<!--[if lte IE 7]> |
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
Show hidden characters
{ | |
"node": true, | |
"esnext": true, | |
"bitwise": true, | |
"camelcase": true, | |
"eqeqeq": true, | |
"eqnull": true, | |
"immed": true, | |
"indent": 2, | |
"latedef": "nofunc", |
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
{ | |
// JSHint Default Configuration File (as on JSHint website) | |
// See http://jshint.com/docs/ for more details | |
"maxerr" : 50, // {int} Maximum error before stopping | |
// Enforcing | |
"bitwise" : true, // true: Prohibit bitwise operators (&, |, ^, etc.) | |
"camelcase" : false, // true: Identifiers must be in camelCase | |
"curly" : true, // true: Require {} for every new block or scope |
NewerOlder