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

Can't get sourcemaps in production? #260

Closed
ghost opened this issue Apr 15, 2017 · 5 comments
Closed

Can't get sourcemaps in production? #260

ghost opened this issue Apr 15, 2017 · 5 comments

Comments

@ghost
Copy link

ghost commented Apr 15, 2017

I've tried adding devtool: 'sourcemap' to the production.js file but I'm still not getting any sourcemaps outputted in the compiled javascript. Am I missing a step?

@p0wl
Copy link
Contributor

p0wl commented Apr 16, 2017

You have to tell uglifyjs that you want sourcemaps: webpack/webpack#2704 (comment)

@gauravtiwari
Copy link
Member

@rainyday As @p0wl suggested, this should fix the issue for you 👍

devtool: 'sourcemap',
new webpack.optimize.UglifyJsPlugin({
    sourceMap: true
 })

@ghost
Copy link
Author

ghost commented Apr 17, 2017

Thanks, that worked!

@gauravtiwari
Copy link
Member

Document this in README/guide - #372

@tavelli
Copy link

tavelli commented Jun 6, 2017

@gauravtiwari do you mean?

devtool: 'source-map'

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

No branches or pull requests

3 participants