@@ -32,36 +32,36 @@ module.exports = {
3232 sandbox : [
3333 require . resolve ( 'babel-polyfill' ) ,
3434 require . resolve ( './polyfills' ) ,
35- path . join ( paths . sandboxSrc , 'index.js' )
35+ path . join ( paths . sandboxSrc , 'index.js' ) ,
3636 ] ,
3737 embed : [
3838 require . resolve ( './polyfills' ) ,
39- path . join ( paths . embedSrc , 'index.js' )
39+ path . join ( paths . embedSrc , 'index.js' ) ,
4040 ] ,
41- vendor : [ 'react' , 'react-dom' , 'styled-components' ]
41+ vendor : [ 'react' , 'react-dom' , 'styled-components' ] ,
4242 } ,
4343 target : 'web' ,
4444 node : {
4545 fs : 'empty' ,
4646 module : 'empty' ,
47- child_process : 'empty'
47+ child_process : 'empty' ,
4848 } ,
4949 output : {
5050 path : paths . appBuild ,
5151 pathinfo : true ,
52- publicPath : '/'
52+ publicPath : '/' ,
5353 } ,
5454
5555 module : {
5656 rules : [
5757 {
5858 test : / c r e a t e - z i p \/ .* \/ f i l e s \/ .* \. i c o $ / ,
59- loader : 'base64-loader'
59+ loader : 'base64-loader' ,
6060 } ,
6161 {
6262 test : / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ,
6363 exclude : [ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* \. i c o $ / ] ,
64- loader : 'raw-loader'
64+ loader : 'raw-loader' ,
6565 } ,
6666 {
6767 test : / \. j s $ / ,
@@ -71,16 +71,16 @@ module.exports = {
7171 / t y p e s c r i p t S e r v i c e s \. j s $ / ,
7272 // Don't do the node modules of the codesandbox module itself
7373 / c o d e s a n d b o x \/ n o d e _ m o d u l e s / ,
74- / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ /
74+ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ,
7575 ] ,
76- loader : 'happypack/loader'
76+ loader : 'happypack/loader' ,
7777 } ,
7878 // JSON is not enabled by default in Webpack but both Node and Browserify
7979 // allow it implicitly so we also enable it.
8080 {
8181 test : / \. j s o n $ / ,
8282 loader : 'json-loader' ,
83- exclude : [ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ]
83+ exclude : [ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ] ,
8484 } ,
8585 // "postcss" loader applies autoprefixer to our CSS.
8686 // "css" loader resolves paths in CSS and adds assets as dependencies.
@@ -90,13 +90,13 @@ module.exports = {
9090 {
9191 test : / \. c s s $ / ,
9292 loaders : [ 'style-loader' , 'css-loader' ] ,
93- exclude : [ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ]
93+ exclude : [ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ] ,
9494 } ,
9595 // For importing README.md
9696 {
9797 test : / \. m d $ / ,
9898 loader : 'raw-loader' ,
99- exclude : [ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ]
99+ exclude : [ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ] ,
100100 } ,
101101 // "file" loader makes sure those assets get served by WebpackDevServer.
102102 // When you `import` an asset, you get its (virtual) filename.
@@ -106,8 +106,8 @@ module.exports = {
106106 exclude : [ / \/ f a v i c o n .i c o $ / , / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ] ,
107107 loader : 'file-loader' ,
108108 options : {
109- name : 'static/media/[name].[hash:8].[ext]'
110- }
109+ name : 'static/media/[name].[hash:8].[ext]' ,
110+ } ,
111111 } ,
112112 // A special case for favicon.ico to place it into build root directory.
113113 {
@@ -116,8 +116,8 @@ module.exports = {
116116 exclude : [ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ] ,
117117 loader : 'file-loader' ,
118118 options : {
119- name : 'favicon.ico?[hash:8]'
120- }
119+ name : 'favicon.ico?[hash:8]' ,
120+ } ,
121121 } ,
122122 // "url" loader works just like "file" loader but it also embeds
123123 // assets smaller than specified size as data URLs to avoid requests.
@@ -127,8 +127,8 @@ module.exports = {
127127 exclude : [ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ] ,
128128 options : {
129129 limit : 10000 ,
130- name : 'static/media/[name].[hash:8].[ext]'
131- }
130+ name : 'static/media/[name].[hash:8].[ext]' ,
131+ } ,
132132 } ,
133133 // "html" loader is used to process template page (index.html) to resolve
134134 // resources linked with <link href="./relative/path"> HTML tags.
@@ -137,12 +137,12 @@ module.exports = {
137137 loader : 'html-loader' ,
138138 exclude : [ / c r e a t e - z i p \/ .* \/ f i l e s \/ .* $ / ] ,
139139 options : {
140- attrs : [ 'link:href' ]
141- }
142- }
140+ attrs : [ 'link:href' ] ,
141+ } ,
142+ } ,
143143 ] ,
144144
145- noParse : [ / e s l i n t \. 4 \. 1 \. 0 \. m i n \. j s $ / , / t y p e s c r i p t S e r v i c e s \. j s $ / ]
145+ noParse : [ / e s l i n t \. 4 \. 1 \. 0 \. m i n \. j s $ / , / t y p e s c r i p t S e r v i c e s \. j s $ / ] ,
146146 } ,
147147
148148 resolve : {
@@ -152,18 +152,18 @@ module.exports = {
152152 extensions : [ '.js' , '.json' ] ,
153153
154154 alias : {
155- moment : 'moment/moment.js'
156- }
155+ moment : 'moment/moment.js' ,
156+ } ,
157157 } ,
158158
159159 plugins : [
160160 new HappyPack ( {
161161 loaders : [
162162 {
163163 path : 'babel-loader' ,
164- query : babelConfig
165- }
166- ]
164+ query : babelConfig ,
165+ } ,
166+ ] ,
167167 } ) ,
168168 // Generates an `index.html` file with the <script> injected.
169169 new HtmlWebpackPlugin ( {
@@ -181,8 +181,8 @@ module.exports = {
181181 keepClosingSlash : true ,
182182 minifyJS : true ,
183183 minifyCSS : true ,
184- minifyURLs : true
185- }
184+ minifyURLs : true ,
185+ } ,
186186 } ) ,
187187 new HtmlWebpackPlugin ( {
188188 inject : true ,
@@ -199,8 +199,8 @@ module.exports = {
199199 keepClosingSlash : true ,
200200 minifyJS : true ,
201201 minifyCSS : true ,
202- minifyURLs : true
203- }
202+ minifyURLs : true ,
203+ } ,
204204 } ) ,
205205 new HtmlWebpackPlugin ( {
206206 inject : true ,
@@ -217,8 +217,8 @@ module.exports = {
217217 keepClosingSlash : true ,
218218 minifyJS : true ,
219219 minifyCSS : true ,
220- minifyURLs : true
221- }
220+ minifyURLs : true ,
221+ } ,
222222 } ) ,
223223 // Makes some environment variables available to the JS code, for example:
224224 // if (process.env.NODE_ENV === 'development') { ... }. See `env.js`.
@@ -239,31 +239,31 @@ module.exports = {
239239 from : __DEV__
240240 ? 'node_modules/monaco-editor/dev/vs'
241241 : 'node_modules/monaco-editor/min/vs' ,
242- to : 'public/vs'
242+ to : 'public/vs' ,
243243 } ,
244244 {
245245 from : 'static' ,
246- to : 'static'
246+ to : 'static' ,
247247 } ,
248248 {
249249 from : 'src/homepage/static' ,
250- to : 'static'
251- }
250+ to : 'static' ,
251+ } ,
252252 ] ) ,
253253 // Try to dedupe duplicated modules, if any:
254254 new webpack . optimize . CommonsChunkPlugin ( {
255255 name : 'common' ,
256- chunks : [ 'app' , 'sandbox' ]
256+ chunks : [ 'app' , 'sandbox' ] ,
257257 } ) ,
258258 new webpack . optimize . CommonsChunkPlugin ( {
259259 name : 'vendor' ,
260- minChunks : Infinity
260+ minChunks : Infinity ,
261261 } ) ,
262262 new webpack . optimize . CommonsChunkPlugin ( {
263263 async : true ,
264264 children : true ,
265- minChunks : 2
265+ minChunks : 2 ,
266266 } ) ,
267- new webpack . NamedModulesPlugin ( )
268- ]
267+ new webpack . NamedModulesPlugin ( ) ,
268+ ] ,
269269} ;
0 commit comments