Skip to content

Make esm amd loader a singleton#430

Merged
aomarks merged 6 commits intoPolymer:esm-singletonfrom
LarsDenBakker:feature/singleton-esm-amd-loader
Jun 11, 2018
Merged

Make esm amd loader a singleton#430
aomarks merged 6 commits intoPolymer:esm-singletonfrom
LarsDenBakker:feature/singleton-esm-amd-loader

Conversation

@LarsDenBakker
Copy link
Contributor

The esm-amd-loader relies on global state, but when it is injected twice the global state is reset.

Polyserve injects the loader multiple times, I'm not sure if polymer build does this as well. In any case it's good practice to return if it was already loaded.

@aomarks aomarks changed the base branch from master to esm-singleton June 11, 2018 18:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants