Search code examples
parceljs

How do I make parcel inline sourcemaps?


By default parcel put source map in a separate file. How do I tell parcel to put source map in the same output file? I guess it is called inline source maps?


Solution

  • See this section of the documentation: https://parceljs.org/features/targets/#sourcemap.

    In your package.json, add the following:

    {
      "targets": {
        "default": {
          "sourceMap": {
            "inline": true
          }
        }
      }
    }
    

    Note that you may need to change "default" to match your own target name, if you've configured other options.