chore: migrate docs/language-models libs to oxlint/oxfmt (oxc increment 2)#3516
Draft
olliejenningsPT wants to merge 1 commit into
Draft
chore: migrate docs/language-models libs to oxlint/oxfmt (oxc increment 2)#3516olliejenningsPT wants to merge 1 commit into
olliejenningsPT wants to merge 1 commit into
Conversation
Move @osdk/language-models, @osdk/react-sdk-docs, and @osdk/typescript-sdk-docs from the ESLint/dprint toolchain to oxlint/oxfmt (the oxc migrated libraries archetype), the second increment of the repo-wide oxc migration (#3031). - monorepolint: move the 3 packages into the oxc archetype (generates the oxlint/oxfmt lint + fix-lint scripts) - lint-staged: route the 3 packages through oxlint --fix + oxfmt - dprint.json: exclude the 3 package dirs (now owned by oxfmt) - oxfmt.config.ts: ignore YAML so significant-whitespace data such as the mustache templates in typescript-sdk-docs/src/documentation.yml is preserved - oxlint.config.ts: disable complexity, unicorn/no-useless-switch-case, and require-unicode-regexp (structural-churn / behavior-changing rules) to keep the migration behavior-preserving - reformat the package sources with oxfmt
Contributor
Storybook PreviewBuilt from commit |
Contributor
size-limit report 📦
|
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.
Summary
Second increment of the repo-wide ESLint→oxlint / dprint→oxfmt migration (#3031). Stacked on #3481 (
pr-3031-2pkgs); that PR needs to merge first.Migrates three published, plain-TypeScript libraries from the ESLint/dprint toolchain to oxlint/oxfmt (via the Ultracite preset), reusing the exact pattern the four
shared.*packages established in #3481:@osdk/language-models@osdk/react-sdk-docs@osdk/typescript-sdk-docsChanges
.monorepolint.config.mjs: move the 3 packages out ofstandardLibrariesinto theoxc migrated librariesarchetype, which regenerates theirlint/fix-lintscripts to use oxlint + oxfmt..lintstagedrc.mjs: add the 3 short names toOXC_PACKAGESso staged files route through oxlint --fix + oxfmt.dprint.json: exclude the 3 package dirs (now owned by oxfmt).oxfmt.config.ts: ignore**/*.yml/**/*.yaml. oxfmt would otherwise reformat significant-whitespace data such as the mustache templates intypescript-sdk-docs/src/documentation.yml, corrupting the generated snippets. (dprint never formatted YAML either — no yaml plugin — so this preserves the status quo.)oxlint.config.ts: extend the shared override block with three rules these packages surfaced, all kept behavior-preserving per the migration philosophy:complexity→ off (large discriminated-unionrenderTypeswitches exceed the ceiling; splitting is pure churn)unicorn/no-useless-switch-case→ off (explicitcase "string"/case "unknown"document intent alongsidedefault)require-unicode-regexp→ off (adding theuflag to a published runtime regex can change matching semantics)Verification
pnpm exec monorepolint check→ exit 0pnpm turbo lint typecheck transpilefor the 3 packages → 0 errorspnpm turbo check(whole repo) → 636/636 greenpnpm turbo transpile(whole repo) → 246/246 greenChangeset:
patchfor all 3 packages.