v4.1.0
Blog-Doc 4.1.0
Highlights
This release improves the build experience with optional formatting support, adds a CLI build command, improves project setup defaults, preserves content directory structure in Git, and refreshes the default theme.
Features
Optional Prettier integration
- Added optional Prettier-powered formatting during builds.
- Prettier is loaded lazily and remains an optional dependency.
- Assets and HTML output are formatted when supported, with graceful fallback behavior.
- Build summaries now show whether formatting was applied.
- Missing Prettier is reported once per build instead of failing silently.
New build CLI
-
Added
npm run buildsupport through a new CLI entry point. -
Uses the same build pipeline as the
/admin/buildroute. -
Returns proper exit codes for automation:
0for successful builds1when build errors occur
Improved project setup and content handling
- Added automatic provisioning of missing config and tooling files.
- Moved default templates into the
defaultsdirectory. - Creates missing parent directories automatically.
- Preserves existing user files by avoiding overwrites.
- Simplified ignored file handling.
- Updated
.gitignorerules to ignore user content while preserving the expected directory structure. - Keeps content directories (
images,pages, andposts) tracked through placeholder files, making fresh installations easier to initialize.
Default theme updates
- Reorganized theme comments.
- Removed unused templates and markup.
- Fixed default menu conditional loading.
Fixes
- Fixed HTML entity decoding in
plainTextExcerptfor numeric, hexadecimal, and named entities. - Prevented malformed excerpt output caused by incorrectly decoded entities.
- Reduced unnecessary filesystem imports and removed unused code paths.
- Improved internal naming clarity around Prettier loading state.
Breaking Changes
None.
Dependency Updates
- Updated modules to their latest versions.
- Bumped version from
4.0.0to4.1.0.
Upgrade Notes
Prettier remains optional. No configuration changes are required, and existing installations continue to work with the lightweight default build behavior.
Existing repositories may want to review their .gitignore rules if they previously ignored the entire app/content/ directory, as the new structure keeps the content folders present while still ignoring user-generated files.
Full Changelog: v4.0.0...v4.1.0