mirror of
https://gitlab.com/soapbox-pub/shakespeare.git
synced 2026-12-05 08:23:34 +00:00
Fix compatibility with leaflet
This commit is contained in:
1 file changed
+8
@@ -61,6 +61,14 @@ export function esmPlugin(packageLock: PackageLock, target?: string): Plugin {
|
||||
}
|
||||
});
|
||||
|
||||
// Legacy (Internet Explorer) "behavior" syntax
|
||||
build.onResolve({ filter: /^#default#/, namespace: "esm" }, (args) => {
|
||||
return {
|
||||
path: args.path,
|
||||
external: true,
|
||||
};
|
||||
});
|
||||
|
||||
// Handle bare imports like "react"
|
||||
build.onResolve({ filter: /^[^./].*/ }, (args) => {
|
||||
const packageName = args.path.startsWith("@")
|
||||
|
||||
Reference in new issue
Block a user