Repository navigation
fix[serialize]: remove circular module dependencies - #2187
Merged
raon0211 merged 6 commits intoNov 6, 2026
Merged
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
added 2 commits
November 6, 2026 00:43
Move every serialize helper into src/util/serialize.ts and its tests into src/util/serialize.spec.ts. The helpers are module-private, so the new es-toolkit/util/serialize subpath only exposes serialize, and the tests exercise them through serialize. Drop the now-unneeded util/serialize/* null export.
# Conflicts: # src/util/serialize/compareValues.ts # src/util/serialize/serialize.ts # src/util/serialize/serializeObject.ts # src/util/serialize/serializePlainObject.ts
import/no-cycle in oxlint already forbids circular imports.
raon0211
added a commit
that referenced
this pull request
Nov 6, 2026
#2192) * test(browser-compat): harvest examples only from exported declarations The case generator turned every JSDoc `@example` in a source file into a browser test case, including those on module-private helpers. After #2187 merged the serialize helpers into src/util/serialize.ts, their examples (serializeString, serializeNumber, ...) became cases that call functions consumers cannot import, which broke the Browser Compat workflow on main. Parse each file with the TypeScript compiler and collect only the JSDoc attached to exported top-level declarations. This also drops the examples on the non-exported RetryOptions and MapCache interfaces, so renumber the retry skip entries, remove the orphaned memoize overrides, and give compat memoize a runnable example of its own so it keeps a test case. * test(compat/memoize): keep the example runnable on Node.js 6 Object.values is not available on Node.js 6, which es-toolkit/compat still supports, so memoize(Object.values) threw 'Expected a function' there. Memoize Object.keys instead. --------- Co-authored-by: T3 Code <t3code@users.noreply.github.com>
Merged
This branch was successfully 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.
Summary
Fixes #2177. Importing
orderByfromes-toolkitproduces circular dependency warnings in Rollup.Changes
orderBydoes not produce circular dependency warnings.