FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

fix: polyfills eager handling when not commonjs by NathanWalker · Pull Request #11057 · NativeScript/NativeScript · GitHub

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension .json  (1) .ts  (1) All 2 file types selected
Only manifest files
Viewed files
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Unified
Split
Hide whitespace
Diff view
Unified
Split
Hide whitespace
3 changes: 2 additions & 1 deletion packages/core/globals/index.ts
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,8 @@ function registerOnGlobalContext(moduleName: string, exportName: string): void {
}

export function installPolyfills(moduleName: string, exportNames: string[]) {
if (global.__snapshot) {
const shouldInstallEagerly = global.__snapshot || !__COMMONJS__;
if (shouldInstallEagerly) {
const loadedModule = global.loadModule(moduleName);
installPolyfillsFromModule(loadedModule, exportNames as any);
} else {
Expand Down

Back | FazBrowse Home | New Git URL