Skip to main content

March20264

Using Claude Code

Been using Claude Code for a week now as a daily coding assistant. A few observations so far.

It is most useful for tasks where the shape of the solution is clear but the execution is tedious — refactoring, writing tests, tracking down why a CSS rule isn't applying. For genuinely novel design problems, talking through the approach matters more than generating code.

The most important habit: read every diff before accepting it. Not because the code is wrong (it usually isn't), but because understanding what changed keeps you in the loop on your own codebase.

JSDoc type comments

Finally moved a mid-sized project from JSDoc type comments to proper TypeScript. The migration took about half a day — less than expected.

The biggest win is not autocompletion or error catching (though those matter). It is that the types act as documentation that stays in sync with the code. Prose comments lie; types don't compile if they do.

One friction point: strict: true surfaces a lot of implicit any that was quietly hiding real assumptions. Fixing each one forced me to think about what the code actually expected — which is the point.

Tried a new approach to note-taking today: writing a one-paragraph summary immediately after reading something, without looking back at the source.

If you can't summarize it from memory, you haven't understood it yet. The constraint forces you to identify the actual core idea rather than collecting sentences that sound important.

Been doing this for a week. The notes are shorter, less polished, and far more useful.

Spent the afternoon profiling a React app with too many unnecessary re-renders. The culprit was a context provider wrapping the entire tree that updated on every keystroke.

The fix was straightforward — split the context into a read context and a dispatch context. Components that only consume state no longer re-render when actions are dispatched. Dropped re-render count from ~80 to ~12 per interaction.

Worth revisiting useMemo and useCallback placement as well. They are often added too eagerly before profiling, and sometimes removed too eagerly after.