core icon indicating copy to clipboard operation
core copied to clipboard

fix: loadEntry default behavior

Open zhangHongEn opened this issue 1 year ago • 9 comments

Description

loadEntry hook returns the unprocessed module according to the original logic, and the current situation will report an error

{
  name: "loadEntryPlugin",
  loadEntry({remoteInfo}) {
    if (remoteInfo.name === "test") {
      return {init, get}
    }
    // other module error
  }
}

Related Issue

Types of changes

  • [ ] Docs change / refactoring / dependency upgrade
  • [x] Bug fix (non-breaking change which fixes an issue)
  • [ ] New feature (non-breaking change which adds functionality)

Checklist

  • [x] I have added tests to cover my changes.
  • [ ] All new and existing tests passed.
  • [ ] I have updated the documentation.

zhangHongEn avatar Sep 05 '24 03:09 zhangHongEn

⚠️ No Changeset found

Latest commit: fd366a85ab72c4f0b6403d947507fca6b9839069

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

changeset-bot[bot] avatar Sep 05 '24 03:09 changeset-bot[bot]

Deploy Preview for module-federation-docs ready!

Name Link
Latest commit 6d0a269a2d0025a3110dda8c14a338f8d0110601
Latest deploy log https://app.netlify.com/sites/module-federation-docs/deploys/66f8ed0f817d950008543571
Deploy Preview https://deploy-preview-2924--module-federation-docs.netlify.app
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

netlify[bot] avatar Sep 05 '24 03:09 netlify[bot]

@zhangHongEn could you add some documentation regarding this, if willing. This would be good information / example to show end users.

ScriptedAlchemy avatar Sep 05 '24 06:09 ScriptedAlchemy

@zhangHongEn could you add some documentation regarding this, if willing. This would be good information / example to show end users.

I'll add it later today

zhangHongEn avatar Sep 05 '24 06:09 zhangHongEn

@zhangHongEn please run code format so CI will pass. nx format:write

ScriptedAlchemy avatar Sep 06 '24 06:09 ScriptedAlchemy

ok

zhangHongEn avatar Sep 06 '24 06:09 zhangHongEn

@ScriptedAlchemy Finished

zhangHongEn avatar Sep 06 '24 06:09 zhangHongEn

How do I execute the test cases locally? @ScriptedAlchemy @2heal1

zhangHongEn avatar Sep 11 '24 03:09 zhangHongEn

@zhangHongEn you can look in the .github workflows area to see how CI tests are executed

ScriptedAlchemy avatar Sep 13 '24 00:09 ScriptedAlchemy