Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.2.0 breaks uglifyjs #30

Closed
xvaara opened this issue Aug 29, 2017 · 14 comments
Closed

0.2.0 breaks uglifyjs #30

xvaara opened this issue Aug 29, 2017 · 14 comments
Labels

Comments

@xvaara
Copy link

xvaara commented Aug 29, 2017

ERROR in static/js/vendor.ec67e09dea199da20c96.js from UglifyJs
Unexpected token: punc (() [./node_modules/vue2-filters/dist/vue2-filters.js:477,0][static/js/vendor.ec67e09dea199da20c96.js:49045,9]

@w4matt
Copy link

w4matt commented Aug 29, 2017

+1 for this. I'm seeing it too.

@jezmck
Copy link

jezmck commented Aug 31, 2017

+1

ERROR in static/js/vendor.73ebb7d933ff013261d1.js from UglifyJs
SyntaxError: Unexpected token punc «(», expected punc «:» [./~/vue2-filters/dist/vue2-filters.js:477,0]

freearhey added a commit that referenced this issue Aug 31, 2017
@freearhey
Copy link
Owner

Thank you all for the help! Package is already updated and the error should disappear.

@jezmck
Copy link

jezmck commented Sep 1, 2017

Sadly, that's not fixed it for me.

Same error as above;

ERROR in static/js/vendor.9d951549d71db2926f90.js from UglifyJs
SyntaxError: Unexpected token punc «(», expected punc «:» [./~/vue2-filters/dist/vue2-filters.js:294,0]

@freearhey
Copy link
Owner

@jezmck please add some information about your environment so I can reproduce this bug itself.

@freearhey freearhey reopened this Sep 1, 2017
@freearhey freearhey added the bug label Sep 1, 2017
@jezmck
Copy link

jezmck commented Sep 1, 2017

@wherefour, did the update fix it for you?

I'm running MacOS X.
The error occurs when I npm run build which runs a WebPack script which, frankly, I don't understand.

(apologies if this doesn't give you what you need)

@w4matt
Copy link

w4matt commented Sep 1, 2017

Yes, it did. Thanks by the way @freearhey.

I'm using it in Rails 5.1 with Webpacker and Yarn, though, so you probably have a different build process. There is a way I can force compilation locally as if it is a "production" environment and that's how I tracked the failed build down to v0.2.0, so maybe you can try that on your end to help diagnose....?

@w4matt
Copy link

w4matt commented Sep 1, 2017

Hmm, I was curious so tried to compile locally again and looks like it does fail that way:

ERROR in wherefour-14da8b16eef7b8e38b3b.js from UglifyJs Unexpected token: punc (() [./node_modules/vue2-filters/dist/vue2-filters.js:294,0][wherefour-14da8b16eef7b8e38b3b.js:49516,9]

if I roll back to v1.9.0 it all compiles fine.....

@w4matt
Copy link

w4matt commented Sep 1, 2017

v.0.1.9 I meant. lol

@w4matt
Copy link

w4matt commented Sep 1, 2017

Not sure if this helps, but it looks like there is an open issue with webpacker 3.0.0 and Heroku: rails/webpacker#739

If I specify v0.1.9 in package.json, it compiles locally. If I change the version to v0.2.0 or v0.2.1, it fails with the error.

Here's the package.json that DOES compile OK:

{
"name": "wfapp",
"private": true,
"engines": {
"node": "^6.11.2",
"yarn": "^0.27.5"
},
"dependencies": {
"@rails/webpacker": "^3.0.0",
"vue": "^2.4.2",
"vue-bootstrap-datetimepicker": "^3.0.0",
"vue-loader": "^13.0.4",
"vue-resource": "^1.3.4",
"vue-template-compiler": "^2.4.2",
"vue2-filters": "^0.1.9"
},
"devDependencies": {
"webpack-dev-server": "^2.7.1"
}
}

@xvaara
Copy link
Author

xvaara commented Sep 5, 2017

Didn't fix it for me. Here's how to replicate it:
https://asciinema.org/a/GDmVmMy0aFX93EDZeEKnMGa3r

@Ewocker
Copy link

Ewocker commented Sep 18, 2017

Fail for me as well:
ERROR in static/js/vendor.fed95415f17c4112acf5.js from UglifyJs
Unexpected token: punc (() [./~/vue2-filters/dist/vue2-filters.js:294,0][static/js/vendor.fed95415f17c4112acf5.js:12184,9]

@gigaprakosa
Copy link

Fail for me too with the latest version. But fine with v.0.1.9.

@jekinney
Copy link

@gigaprakosa stated, Current version:

ERROR in static/js/vendor.efd6b4056f88cc059df7.js from UglifyJs
Unexpected token: punc (() [./~/vue2-filters/dist/vue2-filters.js:294,0][static/js/vendor.efd6b4056f88cc059df7.js:32548,9]

Rolled back to 0.19 good to go

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

7 participants