sleexyz / dir-loader

Dynamically require a directory in Webpack. Use Webpack as a CMS!
13 stars 5 forks source link

Unexpected token: punc ([) #20

Open AlexRadch opened 7 years ago

AlexRadch commented 7 years ago

When I ran npm run build I got this error

ERROR in static/js/app.7d7a0b90e70004bb1284.js from UglifyJs
Unexpected token: punc ([) [./~/dir-loader!./~/babel-loader/lib!./~/eslint-loader??ref--0!./src/inst-pics.config.js:9,0][static/js/app.cabbd436a235ebbfb4a8.js:166,10]

Next script was generated: app.cabbd436a235ebbfb4a8.js.txt

Error to compile line 166,10 with next code [Symbol.for("__location__")]: [ "Folder01", "Folder01", "Folder01", "01.jpg" ],

I use vue-webpack-boilerplate https://github.com/vuejs-templates/webpack for my project.

sleexyz commented 7 years ago

I don't maintain this project anymore. This was developed in the days before before babel and ES6. You're welcome to fork it and make it work :)