Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot find source file warnings #18

Closed
kennethkoontz opened this issue Jul 14, 2016 · 4 comments
Closed

Cannot find source file warnings #18

kennethkoontz opened this issue Jul 14, 2016 · 4 comments
Assignees
Projects
Milestone

Comments

@kennethkoontz
Copy link

kennethkoontz commented Jul 14, 2016

Not sure if this is the correct place to report this issue but when adding new node packages, sometimes I get errors as such:

WARNING in ./~/ng2-modal/index.js
Cannot find source file '../../../src/index.ts': Error: Cannot resolve 'file' or 'directory' ../../../src/index.ts in /Users/kenneth/Projects/benchmark/web-client/node_modules/ng2-modal

Adding the following exclude entry to my webpack configuration suppresses the warning:

      {
        test: /\.js$/,
        loader: 'source-map-loader',
        exclude: [
          helpers.root('node_modules/ng2-modal')
        ]
      }

What can I do to resolve this without excluding to suppress the warning?

@kennethkoontz kennethkoontz changed the title Cannot find source file Cannot find source file warnings Jul 14, 2016
@jacob-robertson
Copy link

I'm seeing this as well. It's very inconvenient, since the warnings make the actual output difficult to read.
I've included my sample configuration and output.

SampleConfig.zip

Sample output

@johanssonfredrik
Copy link

I am also seeing this problem.

We have a npm linked dependency that we are unable to exclude from the sourcemapping. It seems that the path resolves incorrectly. If i exclude relative path 'node_modules/' it do not exclude it but if i give a absolute path the exclusion works.

@michael-ciniawsky
Copy link
Member

Eventually fixed by #68

@michael-ciniawsky michael-ciniawsky added this to the 0.2.4 milestone Aug 14, 2018
@alexrqs
Copy link

alexrqs commented Mar 5, 2019

Hi, @kennethkoontz will you be so kind and tell me what’s ‘helpers.root’ where that came from?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

No branches or pull requests

6 participants