Skip to content

refactor(core): simplify parsers with Array.from map function - #1084

Open
btea wants to merge 1 commit into
nodejs:mainfrom
btea:refactor/Array.from
Open

refactor(core): simplify parsers with Array.from map function#1084
btea wants to merge 1 commit into
nodejs:mainfrom
btea:refactor/Array.from

Conversation

@btea

@btea btea commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Description

Replace intermediate Array.from(...).map(...) chains in parseChangelog and parseIndex with Array.from(iterable, mapFn), removing the extra intermediate array allocation.
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/from#mapfn

Validation

Related Issues

Check List

  • I have read the Contributing Guidelines and made commit messages that follow the guideline.
  • I have run node --run test and all tests passed.
  • I have check code formatting with node --run format:check & node --run lint.
  • I've covered new added functionality with unit tests if necessary.

@btea
btea requested a review from a team as a code owner September 5, 2026 00:55
@vercel

vercel Bot commented Sep 5, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
api-docs-tooling Ready Ready Preview Sep 5, 2026 12:57am UTC

Request Review

@codecov

codecov Bot commented Sep 5, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 90.60%. Comparing base (de3427a) to head (d49db98).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1084      +/-   ##
==========================================
- Coverage   90.60%   90.60%   -0.01%     
==========================================
  Files         217      217              
  Lines       20802    20801       -1     
  Branches     1974     1974              
==========================================
- Hits        18847    18846       -1     
  Misses       1948     1948              
  Partials        7        7              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions

github-actions Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

api-links Generator

Performance estimate (single CI run)

  • Generation time: 8.5% slower (1.30 s → 1.41 s)
  • Peak memory: 23.6% higher (350.30 MB → 433.13 MB)

legacy-html Generator

Performance estimate (single CI run)

  • Generation time: 0.9% slower (41.48 s → 41.84 s)
  • Peak memory: 0.4% higher (2.57 GB → 2.58 GB)

legacy-json Generator

Performance estimate (single CI run)

  • Generation time: 60.9% faster (36.22 s → 14.17 s)
  • Peak memory: 5.5% higher (1.89 GB → 2.00 GB)

llms-txt Generator

Performance estimate (single CI run)

  • Generation time: 7.1% slower (19.35 s → 20.73 s)
  • Peak memory: 6.6% lower (2.00 GB → 1.87 GB)

orama-db Generator

Performance estimate (single CI run)

  • Generation time: 2.2% faster (21.38 s → 20.92 s)
  • Peak memory: 3.1% lower (1.97 GB → 1.91 GB)

web Generator

Output size: 1 file changed · net -164.00 B

File size details
File Main PR Change
all.html 32.42 MB 32.42 MB -164.00 B (-0.0%)

Performance estimate (single CI run)

  • Generation time: 2.2% slower (124.75 s → 127.44 s)
  • Peak memory: 1.1% higher (5.35 GB → 5.41 GB)

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.

1 participant