Skip to content

docs: Correct dependency type and externals explanation in Authoring Libraries guide#8131

Closed
Abhishekgupta1215 wants to merge 1 commit intowebpack:mainfrom
Abhishekgupta1215:fix_author-lib_lodash
Closed

docs: Correct dependency type and externals explanation in Authoring Libraries guide#8131
Abhishekgupta1215 wants to merge 1 commit intowebpack:mainfrom
Abhishekgupta1215:fix_author-lib_lodash

Conversation

@Abhishekgupta1215
Copy link
Copy Markdown

Closes #6896

Motivation
This PR fixes incorrect guidance in the Authoring Libraries guide around dependency classification for lodash.

The guide previously suggested installing lodash as a dev dependency and described it as a peer dependency when externalized. Since lodash is directly imported by library source code, it should be documented as a regular dependency. The externals configuration should be explained as a bundling strategy, not a dependency-type rule.

What changed

Updated install instructions to:
keep webpack and webpack-cli in devDependencies
install lodash as a regular dependency
Replaced wording that implied lodash should be a peer dependency
Clarified externals behavior:
lodash is not bundled into library output
consumer bundlers can deduplicate lodash
script-tag consumers must provide lodash separately
What kind of change does this PR introduce?
docs

Did you add tests for your changes?
No. This is a documentation-only change and does not modify runtime behavior.

Does this PR introduce a breaking change?
No.

If relevant, what needs to be documented once your changes are merged or what have you already documented?
This PR itself updates the relevant documentation in the Authoring Libraries guide, so no additional follow-up docs are required.

Use of AI
Yes. I used AI assistance to help draft and refine documentation wording and structure. I reviewed all generated text, checked its technical correctness, and made final decisions manually.

@vercel
Copy link
Copy Markdown

vercel bot commented Mar 27, 2026

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

Project Deployment Actions Updated (UTC)
webpack-js-org Ready Ready Preview, Comment Mar 27, 2026 2:38pm

Request Review

@linux-foundation-easycla
Copy link
Copy Markdown

linux-foundation-easycla bot commented Mar 27, 2026

CLA Signed
The committers listed above are authorized under a signed CLA.

  • ✅ login: Abhishekgupta1215 / name: Abhishek Gupta (0328906)

Copy link
Copy Markdown
Member

@alexander-akait alexander-akait left a comment

Choose a reason for hiding this comment

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

That is wrong

@alexander-akait
Copy link
Copy Markdown
Member

Duplicate of #8094

@alexander-akait alexander-akait marked this as a duplicate of #8094 Mar 27, 2026
@Abhishekgupta1215 Abhishekgupta1215 deleted the fix_author-lib_lodash branch March 27, 2026 18:04
@Abhishekgupta1215 Abhishekgupta1215 restored the fix_author-lib_lodash branch March 27, 2026 18:15
@Abhishekgupta1215 Abhishekgupta1215 deleted the fix_author-lib_lodash branch March 27, 2026 18:15
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.

Misguiding document on authoring libraries

2 participants