Skip to content

Conversation

@JLHwung
Copy link
Contributor

@JLHwung JLHwung commented Nov 17, 2025

Q                       A
Fixed Issues? babel-standalone throws "Invalid plugin specified in Babel options: foo, [Object object]" when provided an invalid plugin with options.
Patch: Bug Fix? Yes
Major: Breaking Change?
Minor: New Feature?
Tests Added + Pass? Yes
Documentation PR Link
Any Dependency Changes?
License MIT

In this PR we enabled a few previously disabled ts-eslint rules.

  • array-type
  • consistent-generic-constructors
  • consistent-indexed-object-style
  • no-base-to-string
  • no-unsafe-declaration-merging

The no-base-to-string rule detects a potential bug in the babel-standalone error message handling. This bug is also fixed in this PR.

The following rules have been deprecated and replaced by third-party ts-eslint plugins. Before we install other plugins, they can be safely removed from our config:

  • ban-types
  • sort-type-constituents

@JLHwung JLHwung added PR: Polish 💅 A type of pull request used for our changelog categories pkg: standalone labels Nov 17, 2025
@babel-bot
Copy link
Collaborator

babel-bot commented Nov 17, 2025

Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/60221

@pkg-pr-new
Copy link

pkg-pr-new bot commented Nov 17, 2025

Open in StackBlitz

commit: 68056df

Copy link
Member

@nicolo-ribaudo nicolo-ribaudo left a comment

Choose a reason for hiding this comment

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

I would have slightly preferred the last commit to be in a separate PR.

The ban-types rule has been removed in ts-eslint v8.
This rule has been deprecated in favor of the perfectionist/sort-intersection-types and perfectionist/sort-union-types rules. Since we have installed perfectionist, removing this rule becomes no-op.
@JLHwung JLHwung removed PR: Polish 💅 A type of pull request used for our changelog categories pkg: standalone labels Nov 24, 2025
@JLHwung JLHwung changed the title Polish(standalone): improve message on invalid preset/plugin chore: enable some ts-eslint rules Nov 24, 2025
@JLHwung
Copy link
Contributor Author

JLHwung commented Nov 24, 2025

I would have slightly preferred the last commit to be in a separate PR.

OK, the last two commits are moved to #17606

@JLHwung JLHwung merged commit 99dcba5 into babel:main Nov 24, 2025
74 checks passed
@JLHwung JLHwung deleted the ts-eslint-rules branch November 24, 2025 20:56
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.

3 participants