Repository navigation
chore: update tooling - #353
Merged
Merged
Conversation
- Added allowBuilds for '@swc/core' and 'esbuild' in pnpm-workspace.yaml - Excluded minimum release age for [email protected] - Changed moduleResolution from 'Node' to 'Bundler' in tsconfig.json
…sistency - Updated type definitions in `githubContext.ts`, `githubFetcher.ts`, `githubParameters.ts`, and `githubSchemas.ts` to use single-line union types for better clarity. - Simplified the `RemoveIndex` type utility in `schemaToTypeAliasDeclaration.ts`. - Made minor formatting adjustments in `README.md` for consistency. - Updated `pnpm-workspace.yaml` to use consistent quotation marks. run check and fix
Contributor
Author
|
@fabien0102 hi there, any chance we get this merged? |
Owner
|
On it, sorry for the delay, this PR is HUGE! |
fabien0102
reviewed
Oct 26, 2026
fabien0102
reviewed
Oct 26, 2026
fabien0102
reviewed
Oct 26, 2026
fabien0102
reviewed
Oct 26, 2026
fabien0102
reviewed
Oct 26, 2026
fabien0102
reviewed
Oct 26, 2026
fabien0102
reviewed
Oct 26, 2026
fabien0102
reviewed
Oct 26, 2026
fabien0102
reviewed
Oct 26, 2026
… polyfill for Node 20
11 of 44 tasks
Contributor
Author
|
Hi @fabien0102! 👋 All review feedback has been addressed and the review threads have been resolved:
CI ( (Note: I updated the issue link to keep #348 open so it can track the upcoming TypeScript 7 migration in Draft PR #355) |
fabien0102
reviewed
Oct 28, 2026
Comment on lines
+5
to
+17
| // Polyfill Promise.withResolvers for Node 20 environments (required by @mswjs/interceptors / nock 15) | ||
| if (typeof Promise.withResolvers === "undefined") { | ||
| Promise.withResolvers = function <T>() { | ||
| let resolve!: (value: T | PromiseLike<T>) => void; | ||
| let reject!: (reason?: unknown) => void; | ||
| const promise = new Promise<T>((res, rej) => { | ||
| resolve = res; | ||
| reject = rej; | ||
| }); | ||
| return { promise, resolve, reject }; | ||
| }; | ||
| } | ||
|
|
Owner
There was a problem hiding this comment.
Let’s remove this and bump the CI to the latest node LTS
Contributor
Author
There was a problem hiding this comment.
Done! Removed the polyfill and bumped Node.js to 22 (latest LTS) in CI workflows.
fabien0102
requested changes
Oct 28, 2026
fabien0102
approved these changes
Oct 29, 2026
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.
OpenAPI Codegen: Tooling and compatibility update
Summary
This PR modernizes the project for the current JavaScript/TypeScript ecosystem and fixes compatibility issues introduced by newer package versions, stricter TypeScript checks, and the current Node runtime.
The goal was to keep the generator stable while updating the repo to a cleaner, faster, and more current toolchain without rewriting the generator architecture itself.
Review Status
All review feedback from @fabien0102 has been addressed:
Promise.withResolverspolyfill and bumped CI workflows to Node.js 22 (Active LTS)..oxlintrc.jsonwith Prettier.plugins/typescript/src/utils/getEnumProperties.ts(removedanyand@ts-ignore).cli/src/commands/InitCommand.tsandcli/src/utils/getGithubToken.ts.@types/node@^26.6.5,got@^16.1.0,oxlint@^1.89.0,prettier@^3.9.10,vitest@^5.0.5).Tests/test (pull_request)) is 100% passing.Related
This PR effectively incorporates and resolves the issues covered by:
fix(cli): remove unused got-fetch dependencyenabledtype fromUseQueryOptions#345 —fix(typescript): derive context enabled type from UseQueryOptions@clack/prompts#346 —chore(deps): update @clack/promptsWhat changed
Tooling and linting
Dependency cleanup
got-fetchdependency and kept the codebase on the supportedgotpackage already in use by the CLI@types/*packages that are now redundant because the actual dependencies ship their own TypeScript declarations@types/node@^26.6.5,got@^16.1.0,oxlint@^1.89.0,prettier@^3.9.10,vitest@^5.0.5TypeScript compatibility
rootDirvalues where required by TypeScript's stricter output-layout checksReact Query migration
Enabledhelper that no longer exists in the current package APIenabledflag pattern based onUseQueryOptions["enabled"]Testing and runtime compatibility
.github/workflows/tests.yamland.github/workflows/release-please.yaml) to Node.js 22 (Active LTS), removing the need forPromise.withResolverspolyfill in testsBreaking changes
TanStack React Query v5 migration
TanStack React Query v5 removed the old
Enabledhelper. Generated code should now use the supportedenabledoption pattern instead of the removed helper.TypeScript configuration modernization
Projects consuming the generator should expect the TypeScript config to follow modern compiler expectations. Older config patterns like deprecated module resolution values and missing
rootDirconfiguration are no longer appropriate under the current TypeScript toolchain.Issues
Fixes #354
Relates to #348 (TypeScript 7 transition tracked in #348 and Draft PR #355)
Validation
The following checks run successfully:
pnpm test runpnpm check:typespnpm check:lintpnpm check:prettierpnpm buildTests/test (pull_request)) passing