Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
76 changes: 76 additions & 0 deletions .github/ISSUE_TEMPLATE/1-bug-report.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
name: 🐛 Bug Report
description: Report a problem with the documentation site or its build tooling
labels: [bug]
body:
- type: markdown
attributes:
value: |
Thank you for reporting a bug! Before submitting, make sure this is the right repository:

- **This repository** — documentation content, generated API docs, build scripts, TypeDoc plugins, and the site theme.
- **[nodejs/doc-kit](https://github.com/nodejs/doc-kit/issues)** — bugs in the underlying Markdown-to-HTML engine (parsing, core rendering). This site uses doc-kit with a custom theme, so visual issues usually belong *here*; engine issues belong there.
- **[webpack/webpack](https://github.com/webpack/webpack/issues)** — bugs in webpack itself.

When in doubt, file it here and we'll move it. Also search existing issues to avoid duplicates.

- type: dropdown
id: area
attributes:
label: Which area is affected?
options:
- Documentation content (pages/)
- Generated API docs (TypeDoc output)
- Build tooling (scripts, plugins)
- Theme / visual appearance
- Not sure
validations:
required: true

- type: textarea
id: description
attributes:
label: Bug description
description: A clear and concise description of what the bug is.
placeholder: When I do X, Y happens instead of Z.
validations:
required: true

- type: textarea
id: reproduction
attributes:
label: Steps to reproduce
description: For site issues, include the affected page URL. For build issues, include the command you ran and its output.
placeholder: |
1. Go to https://webpack.js.org/...
2. ...

OR

1. Run `npm run build`
2. See error
validations:
required: true

- type: textarea
id: expected
attributes:
label: Expected behavior
description: What did you expect to happen instead?

- type: input
id: environment
attributes:
label: Environment
description: For build issues — your Node.js version, npm version, and OS.
placeholder: Node.js 24.x, npm 11.x, macOS 15

- type: dropdown
id: ai
attributes:
label: Have you used AI?
description: If you used AI tooling to generate this issue, please state so per webpack's [AI policy](https://github.com/webpack/governance/blob/main/AI_POLICY.md).
options:
- 'No'
- 'Yes'
validations:
required: true
46 changes: 46 additions & 0 deletions .github/ISSUE_TEMPLATE/2-content-issue.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: 📝 Documentation Content Issue
description: Report incorrect, outdated, or missing documentation content
labels: [documentation]
body:
- type: markdown
attributes:
value: |
Thank you for helping improve the webpack docs! A few notes on where content comes from:

- Guides, concepts, and blog posts live in `pages/` in this repository — report (or fix!) them here.
- **API docs** (`/docs/api/`) are generated from webpack's `types.d.ts` — inaccuracies in type descriptions may need fixing in [webpack/webpack](https://github.com/webpack/webpack), while formatting/generation problems belong here.
- **Loader and plugin pages** are generated from the READMEs of their respective repositories.

- type: input
id: page
attributes:
label: Affected page
description: URL or file path of the page with the problem.
placeholder: https://webpack.js.org/docs/... or pages/guides/...
validations:
required: true

- type: textarea
id: problem
attributes:
label: What is wrong?
description: Describe what is incorrect, outdated, unclear, or missing.
validations:
required: true

- type: textarea
id: suggestion
attributes:
label: Suggested fix
description: If you know what the content should say, tell us — or consider opening a pull request!

- type: dropdown
id: ai
attributes:
label: Have you used AI?
description: If you used AI tooling to generate this issue, please state so per webpack's [AI policy](https://github.com/webpack/governance/blob/main/AI_POLICY.md).
options:
- 'No'
- 'Yes'
validations:
required: true
41 changes: 41 additions & 0 deletions .github/ISSUE_TEMPLATE/3-feature-request.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
name: 🚀 Feature Request
description: Suggest an improvement to the documentation site or its tooling
labels: [enhancement]
body:
- type: markdown
attributes:
value: |
Thanks for the suggestion! Note that feature requests for the underlying Markdown-to-HTML engine belong in [nodejs/doc-kit](https://github.com/nodejs/doc-kit/issues), and feature requests for webpack itself belong in [webpack/webpack](https://github.com/webpack/webpack/issues).

- type: textarea
id: problem
attributes:
label: What problem does this solve?
description: Describe the problem or limitation you are running into.
validations:
required: true

- type: textarea
id: solution
attributes:
label: Proposed solution
description: Describe what you would like to happen.
validations:
required: true

- type: textarea
id: alternatives
attributes:
label: Alternatives considered
description: Any alternative solutions or workarounds you have considered.

- type: dropdown
id: ai
attributes:
label: Have you used AI?
description: If you used AI tooling to generate this issue, please state so per webpack's [AI policy](https://github.com/webpack/governance/blob/main/AI_POLICY.md).
options:
- 'No'
- 'Yes'
validations:
required: true
13 changes: 13 additions & 0 deletions .github/ISSUE_TEMPLATE/config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
contact_links:
- name: 🔧 Bug in the doc-kit rendering engine
url: https://github.com/nodejs/doc-kit/issues
about: Problems with the Markdown-to-HTML engine itself (parsing, core rendering) belong in nodejs/doc-kit. Site-specific theme and content issues belong here.
- name: 📦 Bug or feature request for webpack itself
url: https://github.com/webpack/webpack/issues/new/choose
about: Issues with webpack's behavior — not its documentation — belong in webpack/webpack.
- name: 💬 Questions and help
url: https://github.com/orgs/webpack/discussions
about: Ask questions and get help from the webpack community.
- name: 🔒 Report a security vulnerability
url: https://github.com/webpack/.github/blob/main/.github/SECURITY.md
about: Please report security issues privately following our security policy — never in a public issue.
26 changes: 26 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
version: 2
updates:
- package-ecosystem: npm

Check warning

Code scanning / zizmor

insufficient cooldown in Dependabot updates: missing cooldown configuration Warning

insufficient cooldown in Dependabot updates: missing cooldown configuration
directory: /
schedule:
interval: weekly
open-pull-requests-limit: 10
commit-message:
prefix: chore(deps)
groups:
minor-and-patch:
applies-to: version-updates
update-types:
- minor
- patch

- package-ecosystem: github-actions

Check warning

Code scanning / zizmor

insufficient cooldown in Dependabot updates: missing cooldown configuration Warning

insufficient cooldown in Dependabot updates: missing cooldown configuration
directory: /
schedule:
interval: weekly
commit-message:
prefix: chore(ci)
groups:
actions:
patterns:
- '*'
75 changes: 75 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# Contributing to webpack.js.org

Welcome, and thank you for helping improve webpack's documentation! This repository holds the hand-written content and the build tooling behind [webpack.js.org](https://webpack.js.org).

We hope this guide helps you find the right kind of contribution and get productive quickly, however, you should also check out other guide-like resources in this repository:

- The [Writer's Guide](pages/guides/contributing/writers-guide.md)
- The [README](README.md)
- webpack's [AI policy](https://github.com/webpack/governance/blob/main/AI_POLICY.md)

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.

Suggested change
## Table of Contents
- [Does your change belong here?](#does-your-change-belong-here)
- [Writing and improving documentation](#writing-and-improving-documentation)
- [Working on the tooling](#working-on-the-tooling)
- [Local development](#local-development)
- [Code Quality](#code-quality)
- [Opening a pull request](#opening-a-pull-request)
- [Code of Conduct](#code-of-conduct)
- [Licensing](#licensing)

## Does your change belong here?

The website assembles content from several sources, so the first step is confirming you are in the right place:

| You want to change… | Go to… |
| ---------------------------------------------------------- | ------------------------------------------------------------ |
| Guides, blog posts, or other hand-written pages (`pages/`) | **This repository** |
| The build tooling, API doc generation, or site theme | **This repository** |
| Generated API reference pages (`/docs/api/`) | [webpack/webpack](https://github.com/webpack/webpack) |
| Loader or plugin reference pages | The README of that loader or plugin's repository |
| The Markdown-to-HTML engine itself | [nodejs/doc-kit](https://github.com/nodejs/doc-kit) |
| webpack's actual behavior | [webpack/webpack](https://github.com/webpack/webpack/issues) |

When in doubt, [ask in the webpack Discord](https://discord.com/invite/webpack) and we will point you in the right direction.

## Writing and improving documentation

**Read the [Writer's Guide](pages/guides/contributing/writers-guide.md).**

If you want to write something but don't know what, look through [open issues](https://github.com/webpack/webpack.js.org/issues) labeled `documentation`, or start a discussion proposing the topic before investing significant writing time.

## Working on the tooling

The generator code lives in `scripts/` (pipeline stages) and `plugins/` (TypeDoc processing and the doc-kit theme). Start with the [README](README.md) — it explains the three-stage pipeline (prepare → Markdown → HTML) and what each script does.

The site is built on [@node-core/doc-kit](https://github.com/nodejs/doc-kit). Improvements to the engine itself (Markdown parsing, core rendering) belong upstream; the theme and plugins in this repository customize it for webpack.

## Local development

You need the latest LTS release of [Node.js](https://nodejs.org) (CI uses `lts/*`) and npm.

```sh
git clone https://github.com/<your-username>/webpack.js.org.git
cd webpack.js.org
npm ci
npm run build
```

In the above example, `npm run build` runs the whole pipeline (it downloads the webpack releases in `versions.json` and generates their API docs), so it takes a few minutes. After that, if you are only editing hand-written pages, regenerate just the HTML:

```sh
npm run build:html
```
Comment on lines +49 to +53

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Is there any way to preview changes live when I'm only editing a single page, without having to rebuild the entire site?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

for now there is not.
should this feature be at doc-kit side or here?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

probabily doc-kit

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

No, not doc kit, here, I think. Some sort of --watch system, right?

eg look at the diff and only build changed pages + watch


The site is written to `out/` with absolute URLs that expect `http://localhost:3000`, so serve it on that port:

```sh
npx serve out -l 3000 # Port 3000 is default, but it never hurts to be explicit.
```

## Opening a pull request

1. Create a branch on your fork, and try to keep each pull request focused on one change.
2. Follow [Conventional Commits](https://www.conventionalcommits.org/) for commit messages (`feat:`, `fix:`, `docs:`, `chore:`…).
3. A pre-commit hook formats and lints staged files. You can run the same checks yourself with `npm run lint` and `npm run format:check`.
4. If you used AI tooling, read and follow the [AI policy](https://github.com/webpack/governance/blob/main/AI_POLICY.md).
5. A maintainer will review your pull request after it is opened.
Comment on lines +61 to +67

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.

Suggested change
## Opening a pull request
1. Create a branch on your fork, and try to keep each pull request focused on one change.
2. Follow [Conventional Commits](https://www.conventionalcommits.org/) for commit messages (`feat:`, `fix:`, `docs:`, `chore:`…).
3. A pre-commit hook formats and lints staged files. You can run the same checks yourself with `npm run lint` and `npm run format:check`.
4. If you used AI tooling, read and follow the [AI policy](https://github.com/webpack/governance/blob/main/AI_POLICY.md).
5. A maintainer will review your pull request after it is opened.
## Code Quality
A pre-commit hook formats and lints staged files automatically. You can also run the same checks manually:
```sh
npm run lint
npm run format:check

Opening a pull request

  1. Create a branch on your fork, and try to keep each pull request focused on one change.
  2. Follow Conventional Commits for commit messages (feat:, fix:, docs:, chore:…).
  3. If you used AI tooling, read and follow the AI policy.
  4. A maintainer will review your pull request after it is opened.

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.

I hope you got me 😅


## Code of Conduct

This project follows the [OpenJS Foundation Code of Conduct](https://code-of-conduct.openjsf.org). Be kind, be patient, and assume good intent.

## Licensing

Code in this repository is licensed under [MIT](LICENSE). Documentation content in `pages/` is available under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/), consistent with webpack.js.org. By contributing, you agree that your contributions are licensed under these terms.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
Code in this repository is licensed under [MIT](LICENSE). Documentation content in `pages/` is available under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/), consistent with webpack.js.org. By contributing, you agree that your contributions are licensed under these terms.
Code in this repository is licensed under [MIT](LICENSE). Documentation content in `pages/` is available under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/). By contributing, you agree that your contributions are licensed under these terms.

20 changes: 20 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
Copyright Webpack contributors

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

MIT/OpenJSF is more accurate

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

There's no need to assign the copyright to the foundation, but it should be assigned to the project itself, which is webpack


Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
'Software'), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,10 @@ node scripts/markdown/index.mjs .cache/webpack/v5.107.1

## Contributing

See the [contributing guide](CONTRIBUTING.md) for setup instructions, project conventions, and guidance on where issues belong (this repository, [doc-kit](https://github.com/nodejs/doc-kit), or [webpack](https://github.com/webpack/webpack)).

When making changes to documentation generation (plugins, `scripts/markdown/index.mjs`, `tsconfig.json`), ensure the docs can still be generated successfully. CI will verify this on every pull request.

## License

See the [webpack project](https://github.com/webpack/webpack) for license details.
Code in this repository is licensed under [MIT](LICENSE). Documentation content in `pages/` is available under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/), consistent with webpack.js.org.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Suggested change
Code in this repository is licensed under [MIT](LICENSE). Documentation content in `pages/` is available under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/), consistent with webpack.js.org.
Code in this repository is licensed under [MIT](LICENSE). Documentation content in `pages/` is available under [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/).

Loading