Guidance for AI coding agents working in this repository. Tool-agnostic; CLAUDE.md points here.
Bootstrap v6.0.0-alpha1 — CSS/JS framework. Sass source in scss/, TypeScript source in js/src/, docs site in site/ (Astro 5 + MDX).
npm start — dev server (watch + Astro on port 9001)npm run dist — full CSS + JS buildnpm run css — compile, prefix, minify CSSnpm run js — compile + minify JSnpm run css-lint / npm run js-lint — lintnpm run docs-build — build docs sitenpm test — full test suite (lint + dist + tests + docs)Use ASD-STE100 Simplified Technical English for all prose: replies to the user, docs, code comments, commit messages, and PR text.
Be extremely brief. Report the result, not the journey.
Act as a teacher for JavaScript, TypeScript, React, and all JavaScript-family topics.
$component-state-property-size (e.g., $nav-link-disabled-color)@use / @forward only — never @importdefaults(), output via @include tokens($map) on the component root selectorborder-radius / transition properties (use mixins), lighten() / darken(), border: none / outline: none@use → @forward → $variables → --custom-properties → declarations → rules!default (except locals)colors, theme, config, root, reboot, layout, content, forms, components, custom, helpers, utilitiespadding-inline-start over padding-left, etc.color-mix(), light-dark(), range media queries (@media (width >= 1024px))// scss-docs-start name / // scss-docs-end name for docs extractionjs/src/**/*.ts, entry js/src/index.ts); ESM-only, no semicolons, 2-space indent.js extensions (standard TS ESM style); Rolldown resolves them to .ts via resolve.extensionAlias, Vitest via the tsResolve plugin in js/tests/vitest.config.mtsbuild/rolldown.config.mjs, build/build-plugins.mjs) with built-in TS transforms; build/browser-targets.mjs derives the browser floors from .browserslistrc at build time, so there is nothing to keep in sync. Rollup and Babel are gone from the repo — Vitest transforms the specs itselfverbatimModuleSyntax + erasableSyntaxOnly; tsc only type-checks and emits .d.ts (npm run js-typecheck, npm run js-emit-types)BaseComponent (which extends Config); per-component config type XxxConfig typed off Default, refined on the class via protected declare _config: XxxConfigdeclare (no runtime emit); constructor element param stays optional to keep typeof Component assignable to typeof BaseComponent_-prefixed instance member is protected (never private, so subclasses keep access); public API methods and statics stay public. This keeps the internals out of the published .d.ts surfaceNAME, DATA_KEY, EVENT_KEY, VERSIONdom/event-handler.ts, dom/selector-engine.ts, dom/manipulator.tsjs/tests/vitest.config.mts, specs in js/tests/unit/*.spec.js (plain JS, bundled against the TS sources). js/tests/vitest-setup.js maps the Jasmine API the specs are written against onto Vitest — note spyOn stubs by default, unlike vi.spyOn. Async specs return a promise; Vitest 4 dropped done. Coverage is Istanbul over all of js/src, thresholds 90/88/90/90js/tests/types/ — api.ts checks the source (npm run js-typecheck), consumer.ts checks the shipped js/dist/*.d.ts through the package exports map (npm run js-typecheck-dist, after the build). Keep the two in syncsite/src/content/docs/title (required), description (required), toc, aliases, added, mdn, reference, etc.Example, Callout, Code, Details[[docsref:/path/]]### Dependencies heading with <JsDependencies component="<js-src-basename>" /> (before ### Options) on any doc for a js/src/*.ts component. The table is derived at build time by walking the component's import graph in site/src/libs/js-dependencies.ts; never hand-write the file list. When a new source file or third-party package enters the graph, add its human-readable label to FILE_DESCRIPTIONS / PACKAGE_DESCRIPTIONS in that lib (the build throws if a label is missing).StrReplace for targeted edits; avoid full-file rewrites on MDX files to protect typographynpm run css-lint, npm run js-lint, npm run dist, npm run docs-buildconfig.yml, site/src/libs/config.ts (Zod schema), build/rolldown.config.mjs, build/generate-sri.mjs, package.jsonFixes #{issue}, Closes #{issue}, or Supersedes #{pr}.Built output in dist/, _site/, js/dist/ — these are generated.