Skip to content
spatie avatar

Spatie Javascript

Opinionated JavaScript and TypeScript style rules covering declarations, comparisons, functions, destructuring, and Prettier setup.

CCM score
56 of 100
skills.sh installs
606
GitHub stars
101
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers variable declarations, strict equality, function style, pure functions, shorthand methods, and object and array destructuring
  • Sets Prettier defaults of four-space indentation, a 120-character print width, and single quotes
  • Enforces const by default, forbids var, and discourages abbreviated variable names outside terse arrow functions
  • Applies to .js, .ts, .jsx, .tsx, and .vue files, with PHP, CSS-only files, and server configuration out of scope

Install

$ npx -y skills add spatie/guidelines-skills --skill spatie-javascript -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

Spatie JavaScript Guidelines

Overview

Apply Spatie's JavaScript coding standards to keep JS/TS code consistent and readable.

When to Activate

  • Activate this skill for any JavaScript or TypeScript coding work.
  • Activate this skill when working on .js, .ts, .jsx, .tsx, or .vue files.
  • Activate this skill when configuring Prettier for a project.

Scope

  • In scope: JavaScript, TypeScript, Vue single-file components, Prettier configuration.
  • Out of scope: PHP, Laravel, CSS-only files, server configuration.

Workflow

  1. Identify the JavaScript, TypeScript, Vue, or Prettier artifact being changed.
  2. Read references/spatie-javascript-guidelines.md and focus on the relevant sections.
  3. Apply Prettier configuration first, then the language rules relevant to the change.

Details

Repository
github.com/spatie/guidelines-skills
Categories
Frontend & UI Code, Code Review & Quality
First seen
Jun 3, 2026

Questions

What does the spatie-javascript skill do?

It applies Spatie's JavaScript coding standards to tasks that create, edit, review, refactor, or format JavaScript or TypeScript code. It covers variable declarations, comparisons, functions, destructuring, and Prettier configuration, including .js, .ts, .jsx, .tsx, and .vue files.

How do I install the spatie-javascript skill?

Run npx -y skills add spatie/guidelines-skills --skill spatie-javascript -y in your project. Once installed, the agent follows Spatie's conventions such as four-space indentation, single quotes, and a 120-character print width.

Which skills lead the Frontend & UI Code category?

Spatie JavaScript sits in the Frontend & UI Code category alongside vercel-react-best-practices, web-design-guidelines, design-taste-frontend, vercel-composition-patterns, and lark-apps. Its focus is on coding style and Prettier setup rather than UI design or React patterns.

Who is spatie-javascript for?

It suits developers who want their JavaScript and TypeScript code to match Spatie's house style. It applies to any coding task in those languages and to Vue single-file components, but not to PHP, Laravel, CSS-only files, or server configuration.

More from spatie/guidelines-skills

All 4

Similar to Spatie Javascript

More Frontend & UI Code