Skip to content

Commit

Permalink
Fix source-map-support
Browse files Browse the repository at this point in the history
  • Loading branch information
etienne-dldc committed Apr 21, 2020
1 parent e9a2973 commit 884ae2b
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions src/utils/createWebpackConfig.ts
Original file line number Diff line number Diff line change
Expand Up @@ -127,14 +127,7 @@ export function createWebpackConfig(options: CreateWebpackConfigOptions): webpac
new webpack.BannerPlugin({
raw: true,
entryOnly: false,
banner: `require('${
// Is source-map-support installed as project dependency, or linked?
require.resolve('source-map-support').indexOf(process.cwd()) === 0
? // If it's resolvable from the project root, it's a project dependency.
'source-map-support/register'
: // It's not under the project, it's linked via lerna.
require.resolve('source-map-support/register')
}');`,
banner: `require('source-map-support/register');`,
}),
// The FriendlyErrorsWebpackPlugin (when combined with source-maps)
// gives Backpack its human-readable error messages.
Expand Down

0 comments on commit 884ae2b

Please sign in to comment.