界面已本地化;技能介绍与说明文档按所选语言由 AI 自动翻译,代码、命令、路径和专业术语保留原文,以原作者文档为准。
探索技能
开发与工程 · SKILL.md

javascript-tooling

javascript-tooling

【开发与工程】Configure development tools, linting, formatting, and test runners for existing JavaScript projects. Use for ESLint, Prettier, Jest, or equivalent tool setup; defer application implementation and generic project scaffolding.

独立 GitHub 快照 · 自动分类 · 以原作者文档为准

技能说明

GitHub

name: javascript-tooling description: Configure development tools, linting, formatting, and test runners for existing JavaScript projects. Use for ESLint, Prettier, Jest, or equivalent tool setup; defer application implementation and generic project scaffolding. metadata: triggers: files: - '.eslintrc.' - 'jest.config.' - 'package.json' keywords: - eslint - prettier - jest - test - lint - build

JavaScript Tooling

Priority: P1 (HIGH)

Implementation Guidelines

Start tooling recommendations with the applicable Priority and then state the formatting tool and enforcement point.

  • Linting: ESLint (Rec + Prettier). Fix on save.
  • Formatting: Prettier. Run on save/commit.
  • Testing: Jest/Vitest. Co-locate tests. >80% cov.
  • Build: Vite (Apps), Rollup (Libs).
  • Pkg Manager: Sync versions (npm/yarn/pnpm).

Anti-Patterns

  • No Formatting Wars: Prettier rules.
  • No Untested Code: TDD/Post-code tests.
  • No Dirty Commits: Lint before push.

Configuration

// .eslintrc.js
module.exports = {
  extends: ['eslint:recommended', 'prettier'],
  rules: { 'no-console': 'warn', 'prefer-const': 'error' },
};
// .prettierrc
{ "semi": true, "singleQuote": true, "printWidth": 80 }
// jest.config.js
export default {
  coverageThreshold: { global: { lines: 80 } },
};

Reference & Examples

For testing patterns and CI/CD: See references/REFERENCE.md.

Related Topics

best-practices | language

Canonical response anchors

When this skill applies, preserve the following domain terminology or equivalent concrete examples in the answer when relevant:

  • Pkg Manager
  • Priority
  • Testing
我的收藏