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

throw an error if anyone sets skipBabel #2247

Merged
merged 2 commits into from
Feb 11, 2025
Merged
Show file tree
Hide file tree
Changes from all 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
6 changes: 6 additions & 0 deletions packages/compat/src/options.ts
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,12 @@ export function optionsWithDefaults(options?: Options): CompatOptionsType {
);
}

if ((options as any)?.skipBabel !== undefined) {
throw new Error(
`You have set 'skipBabel' on your Embroider options. This setting has been removed and you can now configure your babel ignores directly in the babel config in your repo https://babeljs.io/docs/options#ignore`
);
}

return Object.assign({}, defaults, options);
}

Expand Down
8 changes: 1 addition & 7 deletions tests/addon-template/ember-cli-build.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,5 @@ module.exports = function (defaults) {
*/

const { maybeEmbroider } = require('@embroider/test-setup');
return maybeEmbroider(app, {
skipBabel: [
{
package: 'qunit',
},
],
});
return maybeEmbroider(app);
};
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,5 @@ module.exports = function (defaults) {
},
});

return maybeEmbroider(app, {

skipBabel: [
{
package: 'qunit',
},
],
});
return maybeEmbroider(app);
};
5 changes: 0 additions & 5 deletions tests/fixtures/macro-sample-addon/ember-cli-build.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,5 @@ module.exports = function(defaults) {
return maybeEmbroider(app, {
useAddonAppBoot: false,
useAddonConfigModule: false,
skipBabel: [
{
package: 'qunit',
},
],
});
};
5 changes: 0 additions & 5 deletions tests/scenarios/compat-addon-classic-features-test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,6 @@ appScenarios

return maybeEmbroider(app, {
availableContentForTypes: ['custom'],
skipBabel: [
{
package: 'qunit',
},
],
});
};
`,
Expand Down
5 changes: 0 additions & 5 deletions tests/scenarios/compat-exclude-dot-files-test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,6 @@ appScenarios

return maybeEmbroider(app, {
staticAddonTrees: false,
skipBabel: [
{
package: 'qunit',
},
],
});
};
`,
Expand Down
5 changes: 0 additions & 5 deletions tests/scenarios/router-test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,6 @@ function setupScenario(project: Project) {
staticAddonTrees: true,
staticInvokables: true,
splitAtRoutes: ['split-me'],
skipBabel: [
{
package: 'qunit',
},
],
});
};
`,
Expand Down
5 changes: 0 additions & 5 deletions tests/scenarios/stage1-test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,6 @@ appScenarios
staticComponents: false,
staticHelpers: false,
staticModifiers: false,
skipBabel: [
{
package: 'qunit',
},
],
});
};
`,
Expand Down
1 change: 0 additions & 1 deletion tests/scenarios/static-app-test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,6 @@ wideAppScenarios
},
},
],
skipBabel: [{ package: 'qunit' }, { package: 'macro-decorators' }],
});
};

Expand Down
8 changes: 1 addition & 7 deletions tests/ts-app-template-classic/ember-cli-build.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,5 @@ module.exports = function (defaults) {
'ember-cli-babel': { enableTypeScriptTransform: true },
});

return maybeEmbroider(app, {
skipBabel: [
{
package: 'qunit',
},
],
});
return maybeEmbroider(app);
};
8 changes: 1 addition & 7 deletions tests/ts-app-template/ember-cli-build.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,5 @@ module.exports = function (defaults) {
'ember-cli-babel': { enableTypeScriptTransform: true },
});

return maybeEmbroider(app, {
skipBabel: [
{
package: 'qunit',
},
],
});
return maybeEmbroider(app);
};
Loading