GithubHelp home page GithubHelp logo

Comments (6)

dolanmiu avatar dolanmiu commented on May 22, 2024

Im having the same issue with npm link

edit: i just published my module to npm, and it still doesn't work...

https://www.npmjs.com/package/ng2-mouse-icon

from generator-angular2-library.

jvandemo avatar jvandemo commented on May 22, 2024

This seems to be an issue related to Webpack.

Angular CLI

If you use an Angular CLI generated project, you can resolve this manually by editing angular-cli/models/webpack-build-common.ts in your node_modules directory and adding the following line under the extensions key:

modules: [path.resolve(projectRoot, 'node_modules')]

You can read more details here. There seems to be a fix in the Angular CLI repository so a recent version of Angular CLI will probably fix this automatically.

Angular 2 Webpack Starter

If you are using Angular 2 Webpack Starter (instead of an Anguler CLI project) you can resolve it by changing:

modules: [helpers.root('src'), 'node_modules'] 

to:

modules: [helpers.root('src'), helpers.root('node_modules')]

in your Webpack configuration file.

You can read more details here.

Can you try and see if this works for you? Thanks!

from generator-angular2-library.

sachanacar avatar sachanacar commented on May 22, 2024

Hi all,

Any idea how someone not using webpack (and using SystemJS instead) can solve that issue?

Cheers!
Sacha

from generator-angular2-library.

jvandemo avatar jvandemo commented on May 22, 2024

@sachanacar — Have you found a solution yet for SystemJS? Thanks!

from generator-angular2-library.

jvandemo avatar jvandemo commented on May 22, 2024

Version 8.1.0 of this generator has been released, aligning with the latest Angular Package Format, which should solve this issue.

Feel free to re-open and report back if you experience issues with v8.1.0.

Thanks again for your great feedback! 👍

from generator-angular2-library.

william-lohan avatar william-lohan commented on May 22, 2024

I have an issue with "Unexpected value 'SampleModule' imported by the module 'AppModule'"(got here from #22) with version 11.1.0.

from generator-angular2-library.

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.