Narrow terminals Minimal diffs Format spec Install
Fits narrow terminals

80-char lines fit cleanly in a split terminal. Longer limits force horizontal scroll on one side.

120-char limit
function createOrder(userId: number, items: readonly Item[], shippingAddress: Address, paymentMethod: PaymentMethod): Result<Order> {
    // ...
}
ShotScriptFmt — 80 chars
function createOrder(
    userId: number,
    items: readonly Item[],
    shippingAddress: Address,
    paymentMethod: PaymentMethod,
): Result<Order> {
    // ...
}
Minimal diffs

Trailing commas mean adding a parameter shows one added line. 80-char wrapping means the signature is already split, so nothing else moves.

without trailing commas
@@ long line — rewraps entire signature
-async function getUser(id: number, options: Options): Promise<User | null> {
+async function getUser(id: number, options: Options, fallback: User | null): Promise<User | null> {
     const svc = { db: getDb() }
     return findUserById(svc, id)
 }

@@ already wrapped — still contaminates line above
 async function getUser(
     id: number,
-    options: Options
+    options: Options,
+    fallback: User | null
 ): Promise<User | null> {
     const svc = { db: getDb() }
     return findUserById(svc, id)
 }
ShotScriptFmt — trailing commas + 80 chars
@@ long line → auto-wrapped, 1 line added
 async function getUser(
     id: number,
     options: Options,
+    fallback: User | null,
 ): Promise<User | null> {
     const svc = { db: getDb() }
     return findUserById(svc, id)
 }

@@ already wrapped — 1 line added
 async function getUser(
     id: number,
     options: Options,
+    fallback: User | null,
 ): Promise<User | null> {
     const svc = { db: getDb() }
     return findUserById(svc, id)
 }
Format spec
line width
80
indent
4 spaces
semicolons
none
quotes
single
trailing commas
all
bracket spacing
true
Why these choices: 80 chars fits a split terminal. 4-space indent makes nesting depth visible before it becomes a problem. No semis removes line-noise with no semantic cost. Single quotes are one less keystroke for the common case.

Install
Install with AI — paste into Claude Code, Cursor, or any AI assistant
Add ShotScriptFmt to this project: run npm install --save-dev shotscript, then add "shotscript/fmt" to the extends array in biome.json. Full ShotScript setup →
Manual setup
biome.json
// biome.json
{
  "extends": ["shotscript/fmt"]
}
$ npx @biomejs/biome format --write src/