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

fix: Enable es-modules by default. #889

Merged
merged 1 commit into from Jul 23, 2018

Conversation

coreyfarrell
Copy link
Member

A previous fix for #796 added an es-modules option and set it false by
default. This default was a change of behavior in NYC as previously all
sources were parsed as ES modules by the instrumenter. I believe the
old behavior is the correct default because it allows NYC to work with
modern code. Code which uses certain features which violate strict mode
will have to disable es-modules. This will not effect ES5 which follows
the rules of 'use strict'.

A previous fix for istanbuljs#796 added an es-modules option and set it false by
default.  This default was a change of behavior in NYC as previously all
sources were parsed as ES modules by the instrumenter.  I believe the
old behavior is the correct default because it allows NYC to work with
modern code.  Code which uses certain features which violate strict mode
will have to disable es-modules.  This will not effect ES5 which follows
the rules of 'use strict'.
@coreyfarrell coreyfarrell requested a review from bcoe July 12, 2018 17:14
@coreyfarrell coreyfarrell merged commit d0b76e2 into istanbuljs:master Jul 23, 2018
@coreyfarrell coreyfarrell deleted the es-modules-default branch July 23, 2018 23:02
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 this pull request may close these issues.

None yet

1 participant