Comments (5)
Open conf/webpack.production.js
and change it to:
module.exports = require('./make-webpack-config')({
production: true,
devtool: 'source-map'
});
Then when you build, sourcemaps will be generated for both CSS and JS.
from yarsk.
thanks a lot, commented out line in code could be also useful for others... i've just started exploring devpack coming from browserify :) i've gone through a few starters but yours is the first one not overcomplicating things (except the most basic one)
from yarsk.
Is this supposed to generate maps with the actual ES6 code, before transpilation? It doesn't seem to have any effect for me. With or without the source-map options, I can still see all my index.jsx files in the Chrome Sources tab, but they are post-transpilation.
from yarsk.
@BadDox Is this in production or development? In development, eval
is used, which will show the sourcemap post-transpilation. You can change that by editing the devtool setting in conf/webpack.config.js
:
module.exports = require('./make-webpack-config')({
devtool: 'eval-source-map',
});
Keep in mind that the compilation and rebuilds will be slightly slower with that setting. More on the devtool options can be found in the webpack docs.
from yarsk.
Indeed, that was my issue in development.
from yarsk.
Related Issues (20)
- Webpack newbie HOT 1
- Sourcemaps? HOT 1
- Babel polyfill required for some features/browsers HOT 2
- express and server rendering
- Triying to create a yo angular app HOT 1
- saucelab?
- Cannot GET / HOT 7
- running the /dist using outside server background image is not shown. HOT 1
- css classnames HOT 3
- Segmentation Fault with npm start HOT 3
- Switch to react-transform-hmr once stateless functions are working
- I get an error on npm start
- ReferenceError: couldn't resolve escope/referencer HOT 1
- 40KB bundle? HOT 2
- libsass bindings not found HOT 1
- Update to sass-loader 1.0.0 once stable
- Remove HTML template duplication
- Add expressjs support HOT 4
- question about SEO HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from yarsk.