# Type-safe content models with cf-content-types-generator

How we keep TypeScript and Contentful in lockstep with one CLI command.

![Whiteboard sprint planning](https://images.ctfassets.net/vn734mok6jmo/seed-blog-5/398f8c3d391687214f9010cc382c6c85/seed-blog-5.jpg)

Generated types make field renames safe. Run pnpm typegen, get a compile error in the offending consumer, fix it before merging. That's the loop.

We use cf-content-types-generator with --v10 to match the Contentful SDK's WITHOUT\_UNRESOLVABLE\_LINKS modifier. Types land in apps/web/src/lib/contentful/types and get linted on commit.

If you're building anything bigger than a marketing site, you want this in your pipeline.

**READ MORE**

## Get articles like this in your inbox

Engineering essays on content platforms, React, and the modern web. One email a month.
