Skip to content

Cache invalidation with @module-federation/enhanced #2488

Closed
@ATakaSKY

Description

@ATakaSKY

Describe the bug

Hi team,

I'm encountering an issue with remote entries consistently being the same every time I try to consume them using the following setup:

new ModuleFederationPlugin({
  name: "test",
  filename: "remoteEntry.js",
  remotes: {
    testEditor: "testMF@/ui/remoteEntry.js?v=[Date.now()]"
  },
  new ExternalTemplateRemotesPlugin()
}),

Previously, we relied on the ExternalTemplateRemotesPlugin package before transitioning to @module-federation/enhanced, and it effectively generated date timestamps, ensuring the creation of new remote entries each time. Is there a similar approach available in the new enhanced package? I noticed some changes in the nextjsmf package here, but I'm uncertain if there's a direct equivalent in the enhanced package.

Reproduction

NA

Used Package Manager

npm

System Info

NA

Validations

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions