Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

there should be less require property #382

Closed
loynoir opened this issue Aug 6, 2023 · 2 comments · Fixed by #383
Closed

there should be less require property #382

loynoir opened this issue Aug 6, 2023 · 2 comments · Fixed by #383

Comments

@loynoir
Copy link
Contributor

loynoir commented Aug 6, 2023

Extra require property, like enforceIntegrity

https://github.com/guybedford/es-module-shims/blob/main/index.d.ts#L19

@guybedford
Copy link
Owner

I'm sorry I don't understand the request?

loynoir added a commit to loynoir/es-module-shims that referenced this issue Aug 6, 2023
@loynoir
Copy link
Contributor Author

loynoir commented Aug 6, 2023

For example

https://github.com/guybedford/es-module-shims#polyfill-features

<script>
window.esmsInitOptions = { polyfillEnable: ['css-modules', 'json-modules'] }
</script>

Seems like window.esmsInitOptions = {} is valid, right?

If so

  • Actual: enforceIntegrity: boolean, means esmsInitOptions must have property enforceIntegrity.

  • Expect: enforceIntegrity?: boolean, means esmsInitOptions may not property enforceIntegrity, if have, its value should be nullish or boolean.

@loynoir loynoir mentioned this issue Aug 6, 2023
3 tasks
guybedford pushed a commit that referenced this issue Aug 6, 2023
Co-authored-by: loynoir <loynoir@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants