docs(dom): add example to combine#277
Conversation
Remove shell scripts in the release compressed files. Close #241
There was a problem hiding this comment.
Pull request overview
This PR primarily updates documentation/examples (notably DOM utilities) and applies broad formatting/housekeeping across docs and scripts, while also adjusting parts of the build/release toolchain and local/dev environment setup.
Changes:
- Expanded DOM documentation with combined
genStyleString+addStyleexamples; reorganized related README sections. - Normalized whitespace/formatting across many JSDoc blocks and examples.
- Updated tooling/dev setup (Rollup resolve plugin, lint script globs, Node/Docker/GitHub Actions adjustments) and bumped package version.
Reviewed changes
Copilot reviewed 22 out of 32 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| test/browser.test.js | Normalizes string quoting in a browser env test. |
| src/util.ts | JSDoc whitespace normalization only. |
| src/url.ts | JSDoc whitespace cleanup and trims trailing spaces. |
| src/store.ts | JSDoc whitespace cleanup. |
| src/perf.ts | JSDoc whitespace cleanup. |
| src/load.ts | Minor formatting + JSDoc whitespace cleanup. |
| src/event.ts | JSDoc whitespace cleanup. |
| src/dom.ts | Adds/updates DOM docs examples (including combined usage patterns). |
| src/debug.ts | Adjusts genCustomConsole option handling logic for deprecated isClosed. |
| src/calc.ts | JSDoc whitespace cleanup. |
| src/browser.ts | Formatting cleanup in imports + JSDoc whitespace cleanup. |
| scripts/shell/env-win.sh | Updates Windows dev Node version via nvm. |
| scripts/rollup.config.mjs | Adds @rollup/plugin-node-resolve to build pipeline + minor comment tweak. |
| scripts/release.js | Changes release invocation options (now TOC-only). |
| scripts/git-helper.js | Adds TOC-only option to release helper. |
| scripts/convert/td2md.sh | Removed conversion helper script. |
| scripts/convert/md2td.sh | Removed conversion helper script. |
| scripts/convert/data/td2md.md | Removed conversion fixture. |
| scripts/convert/data/td2md.js | Removed conversion fixture. |
| scripts/convert/data/md2td.md | Removed conversion fixture. |
| scripts/convert/data/md2td.js | Removed conversion fixture. |
| scripts/change-package-name.js | Formatting + eslint disables for scripts context. |
| package.json | Version bump, lint script change, adds rollup resolve dependency. |
| examples/index.ts | Cleans up comments/blank lines in examples. |
| README.md | Reorders/adds docs sections and adds combined DOM examples. |
| Dockerfile | Adds a containerized workflow-like test runner. |
| .vscode/settings.json | Editor settings for Markdown TOC + whitespace/EOL normalization. |
| .github/workflows/publish-npm.yml | Formatting + updates action major versions. |
| .gitattributes | Enforces LF line endings for key file types. |
| .dockerignore | Adds ignore rules for building local Docker image efficiently. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| console.log("release: SCRIPTS_NPM_PACKAGE_VERSION", process.env.SCRIPTS_NPM_PACKAGE_VERSION); | ||
|
|
||
| release(pkgVersion, { canGenerateToc: true }); | ||
| release(pkgVersion, { canGenerateToc: true, enerateTocOnly: true }); |
There was a problem hiding this comment.
release() is invoked with enerateTocOnly: true, which causes the script to exit right after generating the TOC and skip the actual release steps (commit/merge/build/publish/tag). If this file is still intended to be the main release entrypoint (used by npm run release), remove this flag or default it to false; otherwise consider splitting TOC-only behavior into a separate script to avoid accidentally disabling releases.
| release(pkgVersion, { canGenerateToc: true, enerateTocOnly: true }); | |
| release(pkgVersion, { canGenerateToc: true }); |
| async function release (ver, { canGenerateToc = false, enerateTocOnly = false, defaultBranch = "main" } = {}) { | ||
| if (!ver) { |
There was a problem hiding this comment.
The option name enerateTocOnly looks like a typo (missing leading g), and it becomes part of the public release() API (and is referenced by scripts/release.js). Consider renaming it to generateTocOnly (and keeping enerateTocOnly temporarily as a deprecated alias if needed) to avoid a permanently confusing API surface.
| @@ -19,7 +19,7 @@ | |||
| "test": "jest", | |||
| "test:debug": "npm run build:debug && npm run test", | |||
| "test:coverage": "npm run build:debug && npx jest --coverage", | |||
| "lint:fix": "eslint --ext 'js,ts,tsx' --fix ./src ./test ./scripts", | |||
| "lint:fix": "eslint --ext 'js,ts,tsx,mjs' --fix ./src/*.ts ./test/*.js ./scripts/*.js ./scripts/*.mjs", | |||
| "docs": "typedoc --readme ./README.md --excludeProtected --excludePrivate --excludeInternal --hideGenerator", | |||
There was a problem hiding this comment.
This PR’s title indicates a DOM docs-only change, but it also updates build/release tooling (Rollup config, GitHub Actions versions), adds Docker artifacts, and bumps the package version. If these changes are intended, consider updating the PR title/description to reflect the broader scope; otherwise, consider splitting non-doc changes into a separate PR to reduce review/release risk.
No description provided.