.agents/skills/tanstack-config/SKILL.md
Opinionated toolkit for building, versioning, and publishing high-quality JavaScript/TypeScript packages.
npx skillsauth add iEnergyy/opsflow tanstack-configInstall 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.
TanStack Config provides an opinionated, minimal-configuration toolkit for JavaScript/TypeScript package development. It includes Vite-powered build configuration, ESLint presets, publish automation with semantic versioning, and integrations with TypeScript, Prettier, Changesets, and GitHub Actions. Designed for monorepo workflows with pnpm and Nx.
Package: @tanstack/config
Status: Stable
npm install @tanstack/config --save-dev
# or
pnpm add @tanstack/config -D
// vite.config.ts
import { defineConfig, mergeConfig } from 'vitest/config'
import { tanstackViteConfig } from '@tanstack/config/vite'
const config = defineConfig({
// Your custom Vite config
})
export default mergeConfig(
config,
tanstackViteConfig({
entry: './src/index.ts',
srcDir: './src',
exclude: ['./src/__tests__'],
})
)
import { tanstackViteConfig } from '@tanstack/config/vite'
export default tanstackViteConfig({
entry: [
'./src/index.ts',
'./src/adapters.ts',
'./src/utils.ts',
],
srcDir: './src',
})
tanstackViteConfig({
entry: './src/index.ts',
srcDir: './src',
exclude: ['./src/__tests__', './src/**/*.test.ts'],
// Generates ESM and CJS outputs
// Generates .d.ts declaration files
// Handles tree-shaking configuration
})
// eslint.config.js
import { tanstackEslintConfig } from '@tanstack/config/eslint'
export default tanstackEslintConfig
// eslint.config.js
import { tanstackEslintConfig } from '@tanstack/config/eslint'
export default [
...tanstackEslintConfig,
{
rules: {
// Custom overrides
'@typescript-eslint/no-explicit-any': 'warn',
},
},
]
// publish.config.ts or used via CLI
import { tanstackPublishConfig } from '@tanstack/config/publish'
export default tanstackPublishConfig({
// Publint-compliant defaults
// Semantic versioning automation
// Changelog generation
})
{
"name": "@myorg/my-package",
"version": "0.0.0",
"type": "module",
"main": "dist/cjs/index.cjs",
"module": "dist/esm/index.js",
"types": "dist/esm/index.d.ts",
"exports": {
".": {
"import": {
"types": "./dist/esm/index.d.ts",
"default": "./dist/esm/index.js"
},
"require": {
"types": "./dist/cjs/index.d.cts",
"default": "./dist/cjs/index.cjs"
}
}
},
"files": ["dist", "src"],
"scripts": {
"build": "vite build",
"lint": "eslint .",
"test": "vitest"
}
}
{
"compilerOptions": {
"strict": true,
"target": "ES2020",
"module": "ESNext",
"moduleResolution": "bundler",
"declaration": true,
"declarationMap": true,
"sourceMap": true,
"outDir": "./dist",
"rootDir": "./src",
"esModuleInterop": true,
"skipLibCheck": true,
"forceConsistentCasingInFileNames": true
},
"include": ["src"],
"exclude": ["node_modules", "dist"]
}
npx changeset init
npx changeset
# Interactive prompt: select packages, bump type, summary
// .changeset/config.json
{
"$schema": "https://unpkg.com/@changesets/[email protected]/schema.json",
"changelog": "@changesets/cli/changelog",
"commit": false,
"fixed": [],
"linked": [],
"access": "public",
"baseBranch": "main",
"updateInternalDependencies": "patch"
}
# .github/workflows/ci.yml
name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
- run: pnpm install
- run: pnpm build
- run: pnpm lint
- run: pnpm test
# .github/workflows/publish.yml
name: Publish
on:
push:
branches: [main]
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: pnpm/action-setup@v2
- uses: actions/setup-node@v4
with:
node-version: 20
registry-url: 'https://registry.npmjs.org'
- run: pnpm install
- run: pnpm build
- name: Create Release Pull Request or Publish
uses: changesets/action@v1
with:
publish: pnpm publish -r
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
# pnpm-workspace.yaml
packages:
- 'packages/*'
- 'examples/*'
// nx.json
{
"tasksRunnerOptions": {
"default": {
"runner": "nx/tasks-runners/default",
"options": {
"cacheableOperations": ["build", "lint", "test"]
}
}
},
"targetDefaults": {
"build": {
"dependsOn": ["^build"]
}
}
}
// .prettierrc
{
"semi": false,
"singleQuote": true,
"trailingComma": "all",
"printWidth": 80
}
# .editorconfig
root = true
[*]
indent_style = space
indent_size = 2
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
"type": "module" in package.json for ESM-first packagessrc and dist in files for source map debugging.d.ts) for TypeScript consumersexports field in package.json (breaks modern bundlers)"type": "module" (causes ESM import issues)moduleResolution: "bundler" in tsconfiglinked)development
Review UI code for Web Interface Guidelines compliance. Use when asked to "review my UI", "check accessibility", "audit design", "review UX", or "check my site against best practices".
tools
UI/UX design intelligence for web and mobile. Includes 50+ styles, 161 color palettes, 57 font pairings, 161 product types, 99 UX guidelines, and 25 chart types across 10 stacks (React, Next.js, Vue, Svelte, SwiftUI, React Native, Flutter, Tailwind, shadcn/ui, and HTML/CSS). Actions: plan, build, create, design, implement, review, fix, improve, optimize, enhance, refactor, and check UI/UX code. Projects: website, landing page, dashboard, admin panel, e-commerce, SaaS, portfolio, blog, and mobile app. Elements: button, modal, navbar, sidebar, card, table, form, and chart. Styles: glassmorphism, claymorphism, minimalism, brutalism, neumorphism, bento grid, dark mode, responsive, skeuomorphism, and flat design. Topics: color systems, accessibility, animation, layout, typography, font pairing, spacing, interaction states, shadow, and gradient. Integrations: shadcn/ui MCP for component search and examples.
development
Headless UI for virtualizing large element lists at 60FPS in TS/JS, React, Vue, Solid, Svelte, Lit & Angular.
development
Headless UI for building powerful tables & datagrids for TS/JS, React, Vue, Solid, Svelte, Qwik, Angular, and Lit.