Upgrading
Sites created with create-docstatic are updated with the same package, run from the root folder of the site:
npx create-docstatic@latest --update
This command updates the docStatic-owned files and dependency versions, and leaves your content untouched. It works out which files belong to docStatic itself by reading update-manifest.json, a manifest generated from the project's template and shipped with every release.
Before writing anything, the command checks that your git working tree is clean, so you can review the update with git diff afterward. If you have uncommitted changes, commit or stash them first or pass --force to proceed anyway.
The update command accepts these options:
--dry-run: Report what would change without writing anything.--force: Proceed even if the git working tree isn't clean.--tag <dist-tag>: Update to a specificdocstaticpackage version or dist-tag instead oflatest.--no-install: Skip installing dependencies after the update.
Run with --dry-run before updating a site with local customisations, so you can see which files would change before committing to the update.
Related topics
- CLI – docStatic command line scripts.
- Installation – How to install docStatic locally, and start a docStatic site in no time.
- Introduction – docStatic was designed from the ground up to be easily installed and used to get your website up and running quickly.
- Styling and layout – A Docstatic site is a pre-rendered single-page React application. You can style it the way you style React apps.
- Creating pages – Creating pages in the CMS.
- Use of Claude in this project – How Claude Code is used in the docStatic project—feature development, automation, component work, style tooling, information architecture and content review.
- Diagrams – Writing diagrams with Mermaid.