GithubHelp home page GithubHelp logo

Comments (5)

bradleyboy avatar bradleyboy commented on July 2, 2024

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.

zaggino avatar zaggino commented on July 2, 2024

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.

tshddx avatar tshddx commented on July 2, 2024

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.

bradleyboy avatar bradleyboy commented on July 2, 2024

@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.

tshddx avatar tshddx commented on July 2, 2024

Indeed, that was my issue in development.

from yarsk.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.