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

docs(babel): update babelHelpers default description #397

Merged
merged 3 commits into from
May 21, 2020
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/babel/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ We recommend to follow those guidelines for each possible value:
- `'runtime'` - you should use it especially when building libraries with rollup. It has to be used in combination with `@babel/plugin-transform-runtime` and you should also specify `@babel/runtime` as dependency of your package (don't forget to tell rollup to treat it as your external dependency when bundling for `cjs` & `es` formats).
- `'bundled'` - you should use it if you want your resulting bundle to contain those helpers (at most one copy of each). Useful especially if you bundle an application code.
- `'external'` - use it only if you know what you are doing. It will reference helpers on **global** `babelHelpers` object. Used in combination with `@babel/plugin-external-helpers`.
- `'inline'` - this is not recommended. Helpers will be inserted in each file using them. This can cause serious code duplication (this is the default Babel behaviour).
- `'inline'` - this is not recommended. Helpers will be inserted in each file using them. This can cause serious code duplication. **(for reference, this is the default behaviour of Babel, but it is overridden by the `babelHelpers` value of this plugin: to either your own explicit selection, otherwise the default value of `'bundled'` will be used)**
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
- `'inline'` - this is not recommended. Helpers will be inserted in each file using them. This can cause serious code duplication. **(for reference, this is the default behaviour of Babel, but it is overridden by the `babelHelpers` value of this plugin: to either your own explicit selection, otherwise the default value of `'bundled'` will be used)**
- `'inline'` - this is not recommended. Helpers will be inserted in each file using them. This can cause serious code duplication. This is the default Babel behavior as Babel operates on isolated files, as Rollup is a bundler and is project-aware the default of this plugin is `"bundled"`.

How about this one?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Andarist made a further amendment to your suggestion: 14fe234


### `skipPreflightCheck`

Expand Down