vol. 01 — a developer's visual essay

scire.dev

scire  /ˈskiː.re/  v.  to know — Latin, infinitive.

A field journal on the practice of knowing, in software.

§ 01

knowledge, in fragments

Software is rarely understood whole. It is approached in pieces — small honest fragments, each true on its own, none of them complete.

{ reading }

A program is read more than it is written.

The first kindness any author owes the reader is clarity of intent. Code is prose with consequences — a line that confuses tomorrow's reader is a line that has already failed.

function intent(reader) {
  return reader.understand(this) === true;
}
< typing >

Types are quiet documentation.

A type is a small contract — a sentence the compiler will not let you forget. Treat them as a co-author.

"The shape of a function is the easiest comment to keep honest."

{ naming }

Naming is the design.

Half of design is the choice of words. The right name closes a question; the wrong one opens five. Spend the minute. Re-name when the meaning shifts.

  • ·Prefer concrete to clever.
  • ·Prefer short, when short is true.
  • ·Prefer one meaning per word.
< debugging >

A bug is a hypothesis disguised as a defect.

You did not misunderstand the machine; you misunderstood your own theory of it. Print the world. Compare it to your map. Edit the map.

{ patience }

Slow is steady. Steady is fast.

Most haste in software is borrowed from a future that will demand the interest with compound rates. The careful path is the short one, eventually.

"Read the function once more before you change it."

§ 02

the stack of knowing

Years of practice settle in layers — not as a tower but as a deck of pages, each slightly off-square, each leaning on the one beneath.

layer.00 · syntax

syntax

Where the keys are. The semicolons. The braces that close. The week you stop looking at the keyboard.

if (curious) { try() }
layer.01 · semantics

semantics

When syntax becomes meaning. The first time the program does what you meant rather than what you wrote.

// what it means
layer.02 · structure

structure

A function. A module. A boundary. Learning where to draw the lines that nothing has yet drawn for you.

module ::= boundary
layer.03 · systems

systems

Many parts behaving together. Latency. Failure. The interesting questions all become questions about time.

async && eventually
layer.04 · taste

taste

The quiet layer. Knowing which line to delete. Why a thousand-line patch is the wrong answer to a four-line problem.

return less

tap a layer to bring it forward — the others lean back.

§ 03

a small glossary

Words developers use, given the slow definitions they deserve.

refactor v.
to change the shape of code without changing its behaviour. Often: an apology to the future, paid in advance.
heuristic n.
a rule of thumb that fits in the head. The compressed memory of many small failures.
idiomatic adj.
written in the dialect of the people who already live here. The polite form of a language.
leak n.
an abstraction telling the truth about itself, finally, at the wrong moment.
ship v.
to release a draft into the keeping of strangers. The act that converts opinion into evidence.