This guide is for contributors and maintainers.
If you are adopting DareDash in an application, start with README.md and the files inside docs/. This file is specifically for people extending the module, evolving the tokens, or maintaining the component system.
Use this order when working on the library itself:
- README
Product-facing entrypoint and adoption path. - Installation and Configuration
Consumer setup expectations. - Layout Primitives
Human-facing structural reference. - UI Components
Human-facing component reference. - Features, Tokens, and Theming
Design-system and customization model. - Architecture
Conceptual system overview for broader audiences. - Developer Guide
Contributor and maintainer workflows.
AI guidance remains separate in llms.txt.
DareDash is a Nuxt-first UI library with four connected parts:
- a Nuxt module that wires the system into the app
- a component surface made of primitives, wrappers, and widgets
- a token pipeline that produces CSS variables and themes
- a Studio that sits on top of the same runtime and token infrastructure
The important mental model is:
- the module prepares the system
- tokens define the system
- components render the system
- Studio helps evolve the system
The build layer lives mainly in src/ and module.ts.
Its responsibilities include:
- reading token sources
- resolving token references
- generating CSS variable output
- wiring the PostCSS
v()function - registering components with the current prefix
Important files:
module.tssrc/builder/tokens.tssrc/builder/components.tssrc/parser.tssrc/postcss/postcss-v-function.ts
The runtime layer lives mainly in runtime/.
It contains:
- Vue/Nuxt components
- composables
- CSS Modules
- shared utilities
- Studio pages and previews
Important folders:
runtime/components/runtime/composables/runtime/assets/styles/runtime/shared/runtime/studio/
The Nuxt module loads the configured token source and turns it into:
- root-level CSS custom properties
- theme selectors such as
[data-theme="light"] - typed token metadata for the client
The module reads components.config.ts and registers the public component surface using the configured prefix.
This registration supports:
- generated wrappers for simpler components
- direct registration for more complex implementations
Components rely on shared composables for consistency.
Examples:
useBaseComponentshared attr/class handlinguseToasterpublic toast state and APIuseThemeEditorStudio-oriented token editing workflow
Components should not hardcode most visual values.
Instead, CSS Modules consume token-generated custom properties, usually through local --local-* mappings. This is what keeps the library themeable and easier to evolve.
Studio is not a disconnected playground. It relies on the same token pipeline, component runtime, and CSS infrastructure as the rest of the library.
That makes it valuable for:
- internal development
- product review
- theme iteration
- regression inspection
Treat these as application-facing:
- auto-registered DareDash components
- module options:
tokens,prefix,debug useToaster- icon overrides through
appConfig.daredash.icons
Do not treat these as stable consumer APIs:
runtime/components/*runtime/shared/utils/*useBaseComponentuseThemeEditor#dd/*aliases as a primary app-consumer API
When authoring styles inside the library:
- use
v('token.path') - do not manually hardcode generated CSS variable names when the intent is a token reference
The default layering model should stay:
- global token
- component token
- local variable usage
This keeps overrides predictable and reduces visual leakage.
When documenting or implementing visual capabilities, verify all three:
- component TypeScript
runtime/shared/utils/processedAttrs.ts- component CSS module selectors
Do not invent attrs, props, or slots because another UI library supports them.
When adding a new public component:
- decide whether it is a layout primitive, UI primitive, form wrapper, or widget
- register it through the component catalog and module flow
- author styles in
runtime/assets/styles/components/ - expose only the minimum public API needed
- document it in
docs/components.mdand alignllms.txtif the public surface changed
When adding visual controls:
- prefer component tokens over hardcoded values
- keep token names semantic and scoped
- update Studio registry entries if the token should be editable there
- verify human docs stay aligned with the exposed capability
For richer components:
- keep orchestration logic inside dedicated runtime implementation files
- reuse primitives and composables where it improves consistency
- avoid leaking internal coordination details into the public API
Before closing a documentation or public-surface change:
- review links and cross-doc references
- verify props/slots/emits against component code
- verify attrs against
processedAttrs.tsand component CSS
The package is prepared to publish as @pisandelli/daredash.
Recommended release flow:
- Keep package metadata aligned with the public repository:
repository.urlmust match the GitHub repository exactlyhomepageshould point to the READMEbugs.urlshould point to the issue tracker
- Verify the standalone publish artifact:
npm run verify:publish - Publish from GitHub Actions using this repository's
.github/workflows/publish.yml - Configure npm trusted publishing for
@pisandelli/daredash:- npm package settings -> Trusted publishing
- provider: GitHub Actions
- repository:
pisandelli/daredash - workflow filename:
publish.yml
Notes:
publishConfig.access=publicandpublishConfig.provenance=trueare already set inpackage.json- once trusted publishing is enabled, npm will generate provenance attestations automatically for public publishes from GitHub-hosted runners
- the module consumer installs
@pisandelli/daredash, but the Nuxt config key remainsdaredash - run the relevant checks for the changed area
Useful checks include:
npm test
npm run verify:publishCheck intent:
testruns the full module test suite, including Studio and component coverageverify:publishvalidates the package as a standalone published artifact
- Keep
README.mdconsumer-first andREADME.DEV.mdmaintainer-first. - Keep human docs aligned with the real code, not with assumptions from other UI libraries.
- Keep
llms.txtaligned when the public API changes. - Prefer adding tokens and semantic attrs over one-off visual exceptions.
- Preserve the distinction between public API and internal tooling.