-
Notifications
You must be signed in to change notification settings - Fork 74
Closed
Labels
COMMUNITY: PR is welcomedWe think it's a good feature to have but would love for the community to help with the PR for itWe think it's a good feature to have but would love for the community to help with the PR for itbugSomething isn't workingSomething isn't workinghelp wantedExtra attention is neededExtra attention is needed
Description
In the federation plugin when adding a dependency which has multiple exports paths, as shared dependency in remote like this:
federation({
name: "remoteapp",
filename: "remoteEntry.js",
remotes: {},
exposes: {.
'./RemoteApp: './src/bootstrap',
},
shared: {.
"some-package-name":"1.0.0".
}
})
getting following error:
Error [ERR_PACKAGE_PATH_NOT_EXPORTED]: Package subpath './package.json' is not defined by "exports" in \node_modules\<some-package>\package.json
at exportsNotFound (node:internal/modules/esm/resolve:304:10)
at packageExportsResolve (node:internal/modules/esm/resolve:651:9)
at resolveExports (node:internal/modules/cjs/loader:592:36)
at Module._findPath (node:internal/modules/cjs/loader:669:31)
at Module._resolveFilename (node:internal/modules/cjs/loader:1131:27)
at Module._load (node:internal/modules/cjs/loader:986:27)
at Module.require (node:internal/modules/cjs/loader:1233:19)
at require (node:internal/modules/helpers:179:18)
at normalizeShareItem ()
at C:\Users\\Desktop\vite\UI\node_modules\@module-federation\vite\lib\index.cjs:320:21 {
code: 'ERR_PACKAGE_PATH_NOT_EXPORTED'
}
Vite version : 5.4.8
Node.js: 20.16.0
Metadata
Metadata
Assignees
Labels
COMMUNITY: PR is welcomedWe think it's a good feature to have but would love for the community to help with the PR for itWe think it's a good feature to have but would love for the community to help with the PR for itbugSomething isn't workingSomething isn't workinghelp wantedExtra attention is neededExtra attention is needed