Skip to content

Commit

Permalink
[#1] Compiling for prod.
Browse files Browse the repository at this point in the history
  • Loading branch information
Russell Vea committed Oct 8, 2015
1 parent 873412d commit 8747f74
Show file tree
Hide file tree
Showing 7 changed files with 43 additions and 7 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
"test": "karma start",
"posttest": "npm run lint",
"serve": "node server.js --env=dev",
"serve:./public/app/dist": "node server.js --env=./public/app/dist",
"./public/app/dist": "npm run copy & webpack --env=./public/app/dist",
"serve:production": "node server.js --env=dist",
"dist": "npm run copy & webpack --env=dist",
"lint": "eslint ./public/app/src",
"copy": "copyfiles -f ./public/app/src/index.html ./public/app/src/favicon.ico ././public/app/dist",
"clean": "rimraf ./public/app/dist/*",
Expand Down
2 changes: 0 additions & 2 deletions public/app/dist/README.md

This file was deleted.

35 changes: 35 additions & 0 deletions public/app/dist/assets/app.js

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions public/app/dist/assets/app.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion public/app/src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<link href='https://api.mapbox.com/mapbox.js/v2.2.1/mapbox.css' rel='stylesheet' />
</head>
<body>
<div id="app">APPLICATION CONTENT</div>
<div id="app"></div>

<script>__REACT_DEVTOOLS_GLOBAL_HOOK__ = parent.__REACT_DEVTOOLS_GLOBAL_HOOK__</script>
<script src='https://api.mapbox.com/mapbox.js/v2.2.1/mapbox.js'></script>
Expand Down
2 changes: 1 addition & 1 deletion routes/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ var router = express.Router();

/* GET home page. */
router.get('/', function(req, res, next) {
res.render('index', { title: 'Express' });
res.render('index');
});

module.exports = router;
4 changes: 3 additions & 1 deletion views/index.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
{% extends 'base.html' %}

{% block content %}
<h1>Hello, World</h1>
<div id="app"></div>
<script src='https://api.mapbox.com/mapbox.js/v2.2.1/mapbox.js'></script>
<script type="text/javascript" src="/app/dist/assets/app.js"></script>
{% endblock %}

0 comments on commit 8747f74

Please sign in to comment.