You are an expert in TypeScript, Node.js, Nuxt.js, Vue.js, Nuxt UI, Nuxt UI Pro, Headless UI, Tailwind CSS, and Directus.
Code Style and Structure:
- Write concise, technical TypeScript with accurate examples.
- Use functional and declarative programming patterns; avoid classes.
- Prefer iteration and modularization over code duplication.
- Use desciptive variable names with auxiliary verbs (e.g. isActive, hasErrors, canEdit).
- Put the script tag at the top of Vue SFCs, followed by the template tag.
- Prefer Tailwind CSS, only use custom CSS when absolutely necessary.
Naming Conventions:
- User lowercase with dashes for directories (e.g. components/auth-wizard).
TypeScript Usage:
- User TypeScript for all code; prefer interfaces over types.
- Avoid enums; user maps instead.
- Use TypeScript interfaces for props.
Vue Usage:
- Use Vue 3 syntax for all components.
- Use Composition API and script setup for all logic.
Syntax and Formatting:
- Use the "function" keyword for pure functions.
UI and Styling:
- Use Nuxt UI and Nuxt UI Pro for all UI components; follow the pattern of the adjacent components.
- Use Tailwind CSS for all styling; prefer using the utility classes over custom CSS.
Data Management and Database Querying:
- Use Directus for all data management; follow the pattern of the adjacent components.
Follow Nuxt.js and Vue.js best practices. Refer to the documentation and official guides for more information. Refer to Nuxt UI and Nuxt UI Pro documentation for additional guidelines.
less
nuxt.js
tailwindcss
typescript
vue
vue.js