Skip to content

Webpack Hot Module Replacement not disposing of Old <style></style> and <script></script> tags #596

Closed

Description

@IAMtheIAM

HMR does work to add new code to the page live, but it just piles new tags with all their css and JS to the head.

So I end up with the old styles and scripts, PLUS the new styles and scripts, and each time I save I get more and more appended to the head.

Isn't HMR supposed to "dispose" of the old styles and scripts before appending the new ones? What am I missing to make HMR properly dispose of old and tags?

hmr not disposing of old code

Activity

  1. PatrickJS commented on May 17, 2016

    @PatrickJS
    Owner

    sorry I can fix that

  2. IAMtheIAM commented on May 17, 2016

    @IAMtheIAM
    Author

    Ok great, thanks! I'll wait for an update from you.

  3. self-assigned this
    on May 17, 2016
  4. Ledzz commented on Aug 26, 2016

    @Ledzz

    +1 to this issue

  5. PatrickJS commented on Aug 26, 2016

    @PatrickJS
    Owner

    this is fixed in the latest release with removeNgStyles from @angularclass/hmr

  6. PatrickJS commented on Aug 26, 2016

    @PatrickJS
    Owner

    the script tags are there because they're patches

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

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions