Fix loading of Sandy plugins packaged by flipper-pkg
Summary:
Flipper cannot load Sandy plugins packaged by flipper-pkg, because the latter only expose default export, but Sandy API is using named exports instead ("Component" and "plugin").
This change fixes this by exposing both default and named exports from plugin package.
Reviewed By: passy
Differential Revision: D23815769
fbshipit-source-id: 1dd273b2e7b98bd01148506037066c41ffd19eb8
This commit is contained in:
committed by
Facebook GitHub Bot
parent
7aaf5585a2
commit
187fd25fc8
@@ -46,7 +46,7 @@ export default async function runBuild(
|
||||
serializer: {
|
||||
...baseConfig.serializer,
|
||||
getRunModuleStatement: (moduleID: string) =>
|
||||
`module.exports = global.__r(${moduleID}).default;`,
|
||||
`module.exports = global.__r(${moduleID});`,
|
||||
},
|
||||
transformer: {
|
||||
...baseConfig.transformer,
|
||||
|
||||
Reference in New Issue
Block a user