i18n/de/skills/setup-tailwind-typescript/SKILL.md
Tailwind CSS und TypeScript in einem bestehenden Next.js- oder Node.js-Projekt konfigurieren. Behandelt Installation, PostCSS-Setup, TypeScript-Strenge-Einstellungen, Pfad-Aliase und IDE-Integration. Verwenden, wenn Tailwind/TypeScript zu einem vorhandenen Projekt hinzugefügt werden soll oder wenn die Konfiguration nach einem Framework-Upgrade neu eingerichtet werden muss.
npx skillsauth add pjt222/agent-almanac setup-tailwind-typescriptInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Tailwind CSS und TypeScript in einem bestehenden Webprojekt konfigurieren, mit korrektem PostCSS-Setup und IDE-Integration.
package.jsonTailwind und seine Peer-Dependencies installieren.
npm install -D tailwindcss postcss autoprefixer
npx tailwindcss init -p
Dies erstellt:
tailwind.config.js (oder .ts für TypeScript-Projekte)postcss.config.jsFür TypeScript-Projekte den Konfigurationstyp aktualisieren:
# tailwind.config.js in tailwind.config.ts umbenennen
mv tailwind.config.js tailwind.config.ts
Erwartet: tailwind.config.ts und postcss.config.js in Projektroot erstellt.
Bei Fehler: Wenn npx tailwindcss fehlschlägt, mit npm install -D tailwindcss@latest die neueste Version sicherstellen.
tailwind.config.ts bearbeiten, um alle Template-Dateien einzuschließen.
// tailwind.config.ts
import type { Config } from 'tailwindcss'
const config: Config = {
content: [
'./src/pages/**/*.{js,ts,jsx,tsx,mdx}',
'./src/components/**/*.{js,ts,jsx,tsx,mdx}',
'./src/app/**/*.{js,ts,jsx,tsx,mdx}',
],
theme: {
extend: {
// Eigene Design-Tokens hier hinzufügen
colors: {
brand: {
50: '#f0f9ff',
500: '#0ea5e9',
900: '#0c4a6e',
},
},
},
},
plugins: [],
}
export default config
Erwartet: content-Array enthält alle Quell-Dateipfade. TypeScript erkennt Konfigurationstypen ohne Fehler.
Bei Fehler: Wenn Klassen nicht angewendet werden, überprüfen, dass content-Pfade mit der tatsächlichen Dateistruktur übereinstimmen. npx tailwindcss --content './src/**/*.tsx' --output /dev/null zum Testen verwenden.
Die Tailwind-Schicht-Direktiven in die globale CSS-Datei einfügen.
/* src/app/globals.css oder src/styles/globals.css */
@tailwind base;
@tailwind components;
@tailwind utilities;
/* Eigene Basis-Styles darunter */
@layer base {
h1 {
@apply text-2xl font-bold;
}
}
@layer components {
.btn-primary {
@apply px-4 py-2 bg-blue-500 text-white rounded hover:bg-blue-600;
}
}
Erwartet: CSS-Datei hat alle drei @tailwind-Direktiven. Benutzerdefinierte Layer-Definitionen kompilieren ohne Fehler.
Bei Fehler: Wenn @tailwind-Direktiven nicht erkannt werden, sicherstellen, dass PostCSS korrekt konfiguriert ist und tailwindcss im plugins-Array in postcss.config.js steht.
tsconfig.json mit geeigneten Strenge-Einstellungen und Pfad-Aliasen einrichten.
{
"compilerOptions": {
"target": "ES2017",
"lib": ["dom", "dom.iterable", "esnext"],
"allowJs": true,
"skipLibCheck": true,
"strict": true,
"noEmit": true,
"esModuleInterop": true,
"module": "esnext",
"moduleResolution": "bundler",
"resolveJsonModule": true,
"isolatedModules": true,
"jsx": "preserve",
"incremental": true,
"plugins": [
{
"name": "next"
}
],
"paths": {
"@/*": ["./src/*"],
"@/components/*": ["./src/components/*"],
"@/lib/*": ["./src/lib/*"],
"@/types/*": ["./src/types/*"]
}
},
"include": ["next-env.d.ts", "**/*.ts", "**/*.tsx", ".next/types/**/*.ts"],
"exclude": ["node_modules"]
}
Erwartet: tsconfig.json wird von TypeScript ohne Fehler geladen. Pfad-Aliase lösen korrekt auf.
Bei Fehler: Wenn moduleResolution: "bundler" Fehler verursacht (benötigt TypeScript 5.0+), auf "node16" oder "node" zurückfallen.
.vscode/settings.json für Tailwind CSS IntelliSense und TypeScript-Unterstützung konfigurieren.
{
"editor.defaultFormatter": "esbenp.prettier-vscode",
"editor.formatOnSave": true,
"editor.codeActionsOnSave": {
"source.fixAll.eslint": "explicit"
},
"tailwindCSS.experimental.classRegex": [
["cva\\(([^)]*)\\)", "[\"'`]([^\"'`]*).*?[\"'`]"],
["cx\\(([^)]*)\\)", "(?:'|\"|`)([^']*)(?:'|\"|`)"]
],
"typescript.tsdk": "node_modules/typescript/lib",
"typescript.enablePromptUseWorkspaceTsdk": true
}
Empfohlene VS Code-Erweiterungen (.vscode/extensions.json):
{
"recommendations": [
"bradlc.vscode-tailwindcss",
"dbaeumer.vscode-eslint",
"esbenp.prettier-vscode",
"ms-vscode.vscode-typescript-next"
]
}
Erwartet: Tailwind IntelliSense zeigt Klassen-Vervollständigung in TypeScript-Dateien. TypeScript-Fehler erscheinen inline.
Bei Fehler: Wenn IntelliSense fehlt, sicherstellen, dass die Tailwind CSS IntelliSense-Erweiterung installiert ist und tailwindCSS.experimental.classRegex korrekt konfiguriert ist.
Prüfen, ob Tailwind und TypeScript korrekt zusammenarbeiten.
# TypeScript-Kompilierung ohne Ausgabe prüfen
npx tsc --noEmit
# CSS auf Tailwind-Klassen testen
echo '<div class="bg-blue-500 text-white p-4">Test</div>' > /tmp/test.html
npx tailwindcss -i ./src/app/globals.css -o /tmp/output.css --content '/tmp/test.html'
grep "bg-blue-500" /tmp/output.css
Erwartet: tsc --noEmit meldet 0 Fehler. Tailwind-Output-CSS enthält bg-blue-500-Klasse.
Bei Fehler: TypeScript-Fehler identifizieren, indem tsc --noEmit 2>&1 | head -20 ausgeführt wird. Wenn Tailwind-Klassen fehlen, Pfade im content-Array von tailwind.config.ts überprüfen.
tailwind.config.ts mit korrekten content-Pfaden vorhandenpostcss.config.js mit Tailwind CSS-Plugin vorhanden@tailwind-Direktiventsconfig.json mit strict: true und Pfad-Aliasen konfigurierttsc --noEmit meldet keine Fehlercontent-Pfade: Wenn Tailwind-Klassen nicht in der Ausgabe erscheinen, liegt es fast immer daran, dass die Dateipfade nicht mit dem content-Array übereinstimmen. Alle Dateiextensionen und Verzeichnisse explizit auflisten.postcss.config.js muss tailwindcss vor autoprefixer erscheinen.paths ohne baseUrl: Bei Verwendung von paths entweder baseUrl setzen oder sicherstellen, dass das Bundler-Modul-Auflösung unterstützt.@tailwind-Direktiven vs Imports: @import 'tailwindcss/...' funktioniert auch, aber @tailwind base/components/utilities ist idiomatischer in Tailwind v3.@layer: Benutzerdefinierte Klassen im @layer components können von Utilities mit demselben Namen nicht überschrieben werden — Utility-Klassen haben immer höhere Spezifität.strict nach der Einführung: Das nachträgliche Aktivieren von strict: true erzeugt oft Hunderte von Fehlern. Schrittweise mit exactOptionalPropertyTypes, noUncheckedIndexedAccess usw. aktivieren.scaffold-nextjs-app — neues Next.js-Projekt mit Tailwind + TypeScript erstellendeploy-to-vercel — Tailwind + TypeScript-App auf Vercel deployentesting
Launch all available agents in parallel waves for open-ended hypothesis generation on problems where the correct domain is unknown. Use when facing a cross-domain problem with no clear starting point, when single-agent approaches have stalled, or when diverse perspectives are more valuable than deep expertise. Produces a ranked hypothesis set with convergence analysis and adversarial refinement.
tools
Write integration tests for a Node.js CLI application using the built-in node:test module. Covers the exec helper pattern, output assertions, filesystem state verification, cleanup hooks, JSON output parsing, error case testing, and state restoration after destructive tests. Use when adding tests to an existing CLI, testing a new command, verifying adapter behavior across frameworks, or setting up CI for a CLI tool.
development
Screen a proposed trademark for conflicts and distinctiveness before filing. Covers trademark database searches (TMview, WIPO Global Brand Database, USPTO TESS), distinctiveness analysis using the Abercrombie spectrum, likelihood of confusion assessment using DuPont factors and EUIPO relative grounds, common law rights evaluation, and goods/services overlap analysis. Produces a conflict report with a risk matrix. Use before adopting a new brand name, logo, or slogan — distinct from patent prior art search, which uses different databases, legal frameworks, and analysis methods.
tools
Scaffold a new CLI command using Commander.js with options, action handler, three output modes (human-readable, quiet, JSON), and optional ceremony variant. Covers command naming, option design, shared context patterns, error handling, and integration testing. Use when adding a command to an existing Commander.js CLI, designing a new CLI tool from scratch, or standardizing command structure across a multi-command CLI.