AI Guidelines, Rules & Platform Maps
Master AI agent skills, rules, platform maps, context optimization, token reduction, and multi-platform workflows using Boodoo and MCP.
How Boodoo & MCP Slash AI Context & Billing Costs
When prompting Large Language Models (LLMs) with massive third-party CSS or UI libraries, developers typically waste tens of thousands of tokens per prompt re-injecting CSS rules, utility indexes, and component definitions. This balloons LLM context windows, inflates API billing, and increases latency.
Boodoo was engineered with an AI-First Lean Architecture to solve context bloat:
80%+ Token Reduction
Instead of dumping entire framework files into the system prompt, AI agents use the Boodoo MCP server to lazily query only the specific component docs or tokens needed on demand.
Zero-Hallucination Guarantees
Deterministic class naming, standard 12-column mobile-first grid, and zero external runtime dependencies allow models like Claude, GPT-4o, and Gemini to generate code with 100% accuracy on the first turn.
Eliminated Debug Loops
Built-in MCP linting (validate_component_usage)
catches missing form IDs, naked text blocks, and invalid React Native styles before execution, saving
expensive back-and-forth prompt retries.
| Workflow Comparison | Traditional Giant Libraries | Boodoo + Native MCP Tooling | Efficiency Gain |
|---|---|---|---|
| Initial Context Load | ~35,000–60,000 tokens per prompt (docs & class references) | ~800 tokens (canonical llms.txt index) |
98% Context Savings |
| Token Querying | Full CSS stylesheet pasted into prompt context | Single tool call: get_design_token("colors.primary") (~60 tokens) |
99% Token Savings |
| Component Generation | Hallucinated third-party dependencies (Popper, jQuery, Emotion) | Zero external deps; exact verified native primitives | Zero Runtime Failures |
| Code Review & Linting | Manual human inspection or expensive LLM self-correction passes | Instant local MCP AST check: validate_component_usage |
Zero Extra API Cost |
Platform Capability & Architecture Map
Boodoo provides unified design tokens and shared layout semantics across every major modern platform. AI agents can consult this architecture map to determine the exact import paths, component conventions, and design token integration for each target environment:
| Platform Target | Package Entry Points | Supported Capabilities | Agent Behavioral Rules |
|---|---|---|---|
| Web / Vanilla JS |
import boodoo, { Modal, Toast } from 'boodoo';import 'boodoo/css';
|
50+ interactive UI components, 12-col responsive grid, 2D CSS grid, dark mode theming, touch gestures. | Always wrap text nodes in semantic tags (<p>, <span>). Never
place naked text in <div>. Invoke .dispose() on teardown. |
| React & Next.js (Web) |
import { useDisclosure, useCombobox } from 'boodoo/react';import 'boodoo/css';
|
Headless React hooks for disclosures, comboboxes, accordions, and dialog portals with full SSR compatibility. | Ensure form fields have id and/or name. Use controlled/uncontrolled state
seamlessly. |
| Vue 3 & Nuxt |
import { useDisclosure, useCombobox } from 'boodoo/vue';import 'boodoo/css';
|
Headless Vue composables with reactive ref support, automatic transition hooks, and accessibility tree management. | Pass reactive refs directly to composables; leverage v-bind="combobox.inputProps" for
accessible bindings. |
| React Native Mobile (iOS & Android) |
import { Button, Card, BoodooProvider } from 'boodoo/react-native';
|
Modular mobile submodules (surfaces, buttons, inputs, feedback, layout) running on native primitives with Expo Snack support. | Strict Zero Inline Styles: Always use StyleSheet.create(). Never pass
style={{...}} literals. Zero DOM dependencies. |
| Electron & Desktop |
import 'boodoo/css';import { titlebar, frameless } from 'boodoo/desktop';
|
Frameless windows, draggable window header regions, custom titlebars, and native OS desktop tokens. | Apply -webkit-app-region: drag to titlebars and no-drag to interactive
buttons. |
| Universal Design Tokens |
import { colors, spacing, radii } from 'boodoo/tokens';
|
Shared color palettes, generous spacing scale (0.5=8px, 1=20px,
2=36px), elevation, and z-index layers across JS, JSON, SCSS, and LESS. |
Consume CSS variables (var(--boodoo-primary)) on web; consume token imports in React
Native StyleSheet definitions. |
Universal Agent Rules & Guardrails
To ensure consistent, bug-free, and accessible code across all developer environments, Boodoo maintains pre-configured rule files for leading IDEs and AI orchestrators. AI models must strictly adhere to these 5 core rules:
1. Mandatory Form Element Identification
Every <input>, <select>, and
<textarea> must include an id (for label association and accessibility tree
mapping) and/or a name attribute (for form serialization).
2. Semantic Text Wrapping (No Naked Text)
Text nodes must never be placed raw inside structural layout containers
(<div>, <section>, <article>). Text must always be
enclosed in semantic tags (<p>, <span>,
<h1>–<h6>, <label>).
3. Dynamic CSS Theming Variables
Never bake static hex colors (e.g. #7c3aed) into component
styles. Always bind to dynamic CSS custom properties: var(--boodoo-primary),
var(--boodoo-card-bg) for instant light/dark mode cascading.
4. React Native StyleSheet-Only Architecture
Zero inline style object literals (style={{...}}) in JSX
markup. All styling must be declared outside render functions via StyleSheet.create() to
optimize garbage collection and rendering performance.
Pre-Configured Rule Files in Boodoo
Drop these native rule files into your repository or IDE to automatically enforce Boodoo standards:
- Cursor IDE:
.cursor/rules/boodoo.mdc - Anthropic Claude (Code, Desktop, Projects):
CLAUDE.md - Google Gemini & Vertex AI:
GEMINI.md - GitHub Copilot:
.github/copilot-instructions.md - Windsurf (Codeium Cascade):
.windsurfrules - Cline & Roo Code (VS Code):
.clinerules - Autonomous Multi-Agent Swarms:
.agents/AGENTS.md
Recommended Prompt Templates & UI Tastes
Use these battle-tested prompts when directing AI assistants connected to Boodoo:
Prompt 1: Full-Page Responsive Dashboard
"Generate a responsive analytics dashboard using Boodoo.
- Query Boodoo MCP (search_components) for Stat Widget, Data Table, and Filter Bar.
- Structure layout using Boodoo's 12-column mobile-first grid (.container, .row, .col-*).
- Ensure all form controls have unique 'id' and 'name' attributes.
- Ensure all text strings are wrapped in semantic tags (<p>, <span>, <h1>–<h6>).
- Use dynamic tokens var(--boodoo-primary) and var(--boodoo-card-bg).
- Validate the generated markup using the Boodoo MCP tool: validate_component_usage."
Prompt 2: React Native Mobile Screen
"Build a mobile user profile screen using Boodoo React Native.
- Import components from 'boodoo/react-native' (Avatar, Card, Button, StatWidget).
- Import spacing and color tokens from 'boodoo/tokens'.
- Strict Rule: Use StyleSheet.create() exclusively. Do not write inline style literals (style={{...}}).
- Rely solely on native React Native primitives (View, Text, Pressable, StyleSheet).
- Validate the component using Boodoo MCP: validate_component_usage(platform='react-native')."
Why Choose Boodoo for Your Next Project
Whether starting from scratch or building high-scale production systems, Boodoo delivers significant engineering and architectural advantages:
Zero Supply-Chain Risk
Zero runtime npm dependencies in core. No Popper.js, jQuery, lodash, or emotion vulnerabilities. Completely self-contained ESM/CJS bundles.
One Unified Token System
Share the exact same color palette, generous spacing scale, and radii across Web, React, Vue, React Native Mobile, Electron, Sass, and Less.
No Build Step Required
Drop in via CDN or vanilla ES modules for instant prototyping, or integrate into Vite, Next.js, Nuxt, and Metro bundlers seamlessly.
Migrating an Existing Project to Boodoo
Transitioning from Bootstrap, Tailwind CSS, or Material UI to Boodoo is fast, automated, and non-destructive.
Boodoo preserves familiar 12-column grid conventions (.container, .row,
.col-*) and standard component classes (.btn, .card,
.modal, .dropdown) while eliminating Popper.js and jQuery dependencies.
Run Boodoo's automated CLI migration codemod to transform templates in seconds:
# Automatically codemod files in ./src or an entire project
npx boodoo migrate --from=bootstrap ./src
Read the full Bootstrap Migration Guide →
Eliminate fragile PostCSS compile pipelines and 50-class HTML attribute bloat with clean, semantic Boodoo components and 150+ intuitive utility classes.
# Codemod Tailwind HTML/JSX class strings to Boodoo
npx boodoo migrate --from=tailwind index.html
Read the full Tailwind CSS Migration Guide →
Replace heavy third-party React Native component libraries with Boodoo's lightweight, pure native primitives. Boodoo provides Paper-compatible theme adapters:
import { createPaperTheme, lightPaperTheme, darkPaperTheme } from 'boodoo/react-native/paper';
import { PaperProvider } from 'react-native-paper';
// Seamlessly bridge Boodoo universal design tokens to React Native Paper
const theme = createPaperTheme({ dark: false });