Skip to content

Warning-System.Import() is deprecated. Use Import() instead #23426

Closed

Description

@pkrd

Hi,

I am trying to migrate my demos of Angular 5 from Webpack 3 to Webpack 4. Everything works fine but after the dev/prod build, I am getting two warnings.

wepack4wrn

The link below says that to disable the warning you have to use Rule.parser.system: true. But I am not able to think how to use this syntax.

webpack/webpack#6357webpack/webpack#6357, webpack 4.0.0-alpha.5 feedback

Please help!

Activity

  1. trotyl commented on Apr 18, 2018

    @trotyl
    Contributor

    Duplicate of #21560

  2. pkrd commented on Apr 18, 2018

    @pkrd
    Author

    I have gone through all the posts. But still not able to figure out the solution for the warnings. Need some help on the same!

  3. pkrd commented on Apr 18, 2018

    @pkrd
    Author

    How do you apply this syntax -

    •Syntax ◦webpackInclude and webpackExclude are supported by the magic comment for import(). They allow to filter files when using a dynamic expression.
    ◦[new] Using System.import() now emits a warning ◾You can disable the warning with Rule.parser.system: true
    ◾You can disable System.import with Rule.parser.system: false

  4. trotyl commented on Apr 18, 2018

    @trotyl
    Contributor

    Please just ignore that warning for now.

  5. pkrd commented on Apr 18, 2018

    @pkrd
    Author

    Okay! Thank you for your help! But just one question. If I demonstrate the same to client, can I say that these warnings will be fixed in future?

  6. vicb commented on Apr 20, 2018

    @vicb
    Contributor

    closing as duplicate

  7. gudapraveenkumar commented on Nov 8, 2018

    @gudapraveenkumar

    Duplicate of #21560

    Could you tell where the changes needs to be done?

  8. ermarkar commented on Dec 24, 2018

    @ermarkar

    To hide this warning put this code in webpack config module:{[rules[//here]]}

    { test: /[\/\\]@angular[\/\\].+\.js$/, parser: { system: true } },```
    
    https://stackoverflow.com/questions/53913138/what-is-angular-compilation-warning-about-system-import-deprecation
    
  9. angular-automatic-lock-bot commented on Sep 14, 2019

    @angular-automatic-lock-bot

    This issue has been automatically locked due to inactivity.
    Please file a new issue if you are encountering a similar or related problem.

    Read more about our automatic conversation locking policy.

    This action has been performed automatically by a bot.

  10. locked and limited conversation to collaborators on Sep 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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