Skip to content

feat(core): allow omitting lib config#1756

Open
elecmonkey wants to merge 7 commits into
mainfrom
elecmonkey/feat-optional-lib-field
Open

feat(core): allow omitting lib config#1756
elecmonkey wants to merge 7 commits into
mainfrom
elecmonkey/feat-optional-lib-field

Conversation

@elecmonkey

Copy link
Copy Markdown
Member

Summary

This PR allows lib to be omitted from Rslib config when the project only needs the default single library output. Omitting lib now has the same behavior as lib: [{}], while explicit invalid values such as lib: [] or lib: null still fail validation instead of being treated as defaults.

The CLI option path also initializes the implicit default lib item so flags such as --format, --entry, and --dts continue to apply when lib is omitted.

Checklist

  • Tests updated (or not required).
  • Documentation updated (or not required).

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jul 8, 2026

Copy link
Copy Markdown

Deploying rslib with  Cloudflare Pages  Cloudflare Pages

Latest commit: f20df01
Status: ✅  Deploy successful!
Preview URL: https://cb781faa.rslib.pages.dev
Branch Preview URL: https://elecmonkey-feat-optional-lib.rslib.pages.dev

View logs

@elecmonkey elecmonkey marked this pull request as ready for review July 8, 2026 09:03
Copilot AI review requested due to automatic review settings July 8, 2026 09:03

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@Timeless0911

Copy link
Copy Markdown
Contributor

Check mergeRslibConfig and modify some docs or anything need to be changed.

@Timeless0911

Copy link
Copy Markdown
Contributor

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. Swish!

Reviewed commit: af7293d498

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

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.

3 participants