Skip to content

Commit

Permalink
Configure loose option for all class property plugins
Browse files Browse the repository at this point in the history
  • Loading branch information
chriskrycho committed Dec 17, 2021
1 parent 8e1f28e commit 3093fb7
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions lib/babel-options-util.js
Original file line number Diff line number Diff line change
Expand Up @@ -383,7 +383,10 @@ function _addClassProperties(addPlugin, plugins, options, config, parent, projec
);
addPlugin(
plugins,
[require.resolve("@babel/plugin-proposal-private-methods")],
[
require.resolve("@babel/plugin-proposal-private-methods"),
{ loose: options.loose || false }
],
_buildClassFeaturePluginConstraints(
{
after: ["@babel/plugin-proposal-decorators"],
Expand All @@ -395,7 +398,10 @@ function _addClassProperties(addPlugin, plugins, options, config, parent, projec
);
addPlugin(
plugins,
[require.resolve("@babel/plugin-proposal-private-property-in-object")],
[
require.resolve("@babel/plugin-proposal-private-property-in-object"),
{ loose: options.loose || false }
],
_buildClassFeaturePluginConstraints(
{
after: ["@babel/plugin-proposal-decorators"],
Expand Down

0 comments on commit 3093fb7

Please sign in to comment.