Repository navigation
refactor: migrate eslint-internal-rules and docs build shims to TypeScript - #3238
Open
ValentinYoushkevich wants to merge 2 commits into
Open
ValentinYoushkevich wants to merge 2 commits into
ValentinYoushkevich wants to merge 2 commits into
Conversation
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is the follow-up promised in #3236 for the internal lint rules and the docs build shims. The three files in
eslint-internal-rules/are now.tswith ESM exports, andeslint.config.mjsimports them directly, so Node runs them through type stripping exactly like the rules inlib/rules, which the config already loads throughtools/lib/rules.js. The folder is added totsconfig.json, sonpm run tscchecks it too. In the docs,shim/empty.mjsandsrc/process-shim.mjsbecame.ts; they are only consumed by Vite and esbuild, andprocess-shim.tsuses the same@ts-expect-error -- Browsercomments forwindowas the theme does. Behaviour is unchanged.docs/.vitepress/public/service-worker.jsand the integration fixtures' configs stay JavaScript on purpose. Thetools/migration is in #3237.Part of #2777