Skip to content

SourceMapDevToolPlugin not generating a sourcemap #7103

@zecuria

Description

@zecuria

Do you want to request a feature or report a bug?
Bug

What is the current behavior?
option of devtool: "source-map" generates a correct source mapping

however adding SourceMapDevtoolPlugin to plugins array does not produce any source map (tested with the following options):

new webpack.SourceMapDevToolPlugin({
    filename: '[file].map',
    moduleFilenameTemplate: undefined,
    fallbackModuleFilenameTemplate: undefined,
    append: null,
    module: true,
    columns: true,
    lineToLine: false,
    noSources: false,
    namespace: '' 
})

I am not using any other plugins in my config files.

If the current behavior is a bug, please provide the steps to reproduce.

The full configs being used are available in the following gists:

Valid Source Map Config

No Source Map Config

What is the expected behavior?
They should produce the same mappings

Please mention other relevant information such as the browser version, Node.js version, webpack version, and Operating System.
Node.js Version: v8.1.2
Webpack Version: 4.6.0
Webpack Cli: 2.0.15

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions