Skip to content
This repository has been archived by the owner on Feb 8, 2023. It is now read-only.

Commit

Permalink
state.json fix
Browse files Browse the repository at this point in the history
  • Loading branch information
JoeStanton committed Jan 31, 2017
1 parent 1b94b70 commit 0a8b7d1
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
3 changes: 3 additions & 0 deletions dev/browser-app/index.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
import 'whatwg-fetch';
import { makeApp } from '../../site/client';

// Hot reloading when state changes
import _ from '../../assets/state.json'; // eslint-disable-line no-unused-vars, import/extensions, import/no-unresolved

const element = document.querySelector('.js-app');

const handleErrors = response => {
Expand Down
1 change: 0 additions & 1 deletion webpack.base.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ const baseConfig = {
{ from: 'assets/favicons', to: 'assets-honestly/favicons' },
{ from: 'assets/social', to: 'assets-honestly/social' },
{ from: `assets/${robots}`, to: 'robots.txt' },
{ from: 'assets/state.json', to: 'state.json' },
{ from: 'assets/txt', to: 'txt/' },
{ from: 'assets/fonts', to: 'assets-honestly/' },
]),
Expand Down
4 changes: 4 additions & 0 deletions webpack.dev.browser.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ const baseConfig = require('./webpack.base.config');
const webpackMerge = require('webpack-merge').smart;
const HtmlWebpackPlugin = require('html-webpack-plugin');
const ExtractTextPlugin = require('extract-text-webpack-plugin');
const CopyWebpackPlugin = require('copy-webpack-plugin');

const devAppConfig = webpackMerge(baseConfig, {
entry: {
Expand All @@ -16,6 +17,9 @@ const devAppConfig = webpackMerge(baseConfig, {
'/assets-honestly/styles-[contenthash:base64:5].css',
{ allChunks: true }
),
new CopyWebpackPlugin([
{ from: 'assets/state.json', to: 'state.json' },
]),
],
});

Expand Down

0 comments on commit 0a8b7d1

Please sign in to comment.