TL;DR
Ghost 4.19.0 introduces the new {{match}} helper for theme developers, enabling basic comparison operations in templates. This release also adds support for custom theme settings with new types (boolean, color, text, image), improves offer management with status tracking and redemption counting, and enhances system stability with numerous bug fixes. The update includes significant internal refactoring, replacing the deprecated i18n package with tpl throughout the codebase.
Highlight of the Release
- New
{{match}} helper for theme templates enabling basic comparison operations
- Enhanced custom theme settings with support for boolean, color, text, and image types
- Improved offer management with status tracking (active/archived) and redemption counting
- Added boot-time metrics monitoring for better performance tracking
- Fixed issues with post scheduling and publish menu functionality
Migration Guide
Custom Theme Settings
If you're a theme developer using custom theme settings, be aware of the new gscan checks that validate:
- Unknown custom theme settings are not allowed
- Custom settings of type
select must use the match helper against specified options
- Unused custom theme settings will trigger errors
- Custom settings of type
color must have default values
- Boolean settings should be properly formatted
i18n to tpl Migration
The i18n package has been deprecated and replaced with the tpl package throughout the codebase. If you have custom code that relies on the i18n package, you should update it to use tpl instead.
URL Service Decoupling
If you have custom code that interacts with Ghost's URL service, be aware that frontend routing has been decoupled from the URL service. This is an internal change but might affect custom code that relies on these internals.
Upgrade Recommendations
This is a feature release with significant enhancements for theme developers and site owners. The upgrade is recommended for all users, especially those who:
- Develop or use custom themes and want to take advantage of the new custom theme setting types and
{{match}} helper
- Use the Offers feature and want improved management capabilities
- Have experienced issues with undismissable update notifications
- Have encountered problems with post scheduling
The release contains no breaking changes for standard usage patterns, making it a safe upgrade for most installations. As always, it's recommended to backup your database before upgrading.
Bug Fixes
Fixed Post Publishing Issues
- Fixed an issue where incorrect publish type would show in the publish menu after closing and reopening
- Fixed inability to re-schedule a scheduled post
Fixed Notification Handling
- Added filtering of outdated custom notifications to prevent undismissable update notification banners
- Added
createdAtVersion property to newly created notifications to track when notifications were received
- Improved notification handling for major version updates
Fixed Offer Handling with Stripe Checkout
- Fixed an issue where coupons were not correctly being passed to Stripe Checkout
Fixed Boot Order for Theme Services
- Fixed initialization order for theme services to ensure custom theme settings are available when needed
Fixed Integration Tests
- Fixed CI not running integration tests
- Updated exporter to include new database tables
New Features
New {{match}} Helper for Theme Templates
Ghost now includes a new {{match}} helper that allows for basic comparison operations in theme templates. This helper supports equals and not equals comparisons, making it easier to create conditional logic in themes:
{{match title "=" "Getting Started"}}
{{match slug "!=" "welcome"}}
The helper also supports implicit equals (without specifying the "=" operator) and works with SafeStrings for proper boolean handling.
Enhanced Custom Theme Settings
This release adds support for several new custom theme setting types:
- Boolean settings: For toggle/switch options in themes
- Color settings: For color pickers in the theme UI
- Text settings: For multi-line text input
- Image settings: For image selection in themes
These new setting types expand the customization options available to theme developers and site owners.
Improved Offer Management
Ghost now includes enhanced offer management capabilities:
- Added status tracking for offers (active/archived)
- Created offer redemption tracking system
- Added filtering of offers by status
- Restricted archived offers from being used for checkout
- Added new offers endpoint on members API for Portal integration
Portal Offers UI
The Portal now includes a dedicated offers screen that displays offer details and handles offer URLs appropriately for both potential and existing paid members.
Boot-time Metrics Monitoring
Added a new metrics system to monitor and track Ghost's boot-time performance, which helps identify performance impacts from code changes across different versions.
Security Updates
No significant security fixes were included in this release.
Performance Improvements
Boot-time Performance Monitoring
- Added metric-shipping to monitor boot-time performance
- Included ghost-version in metrics to track performance changes across versions
Email Analytics Improvements
- Added debug output to email analytics jobs for better visibility into internal services fetching email events
- Improved debugging capabilities for email analytics providers
Cache Invalidation Improvements
- Improved site cache invalidation when adding and editing offers to prevent conflicts with offer redirects
Impact Summary
Ghost 4.19.0 delivers significant improvements for theme developers with the new {{match}} helper and expanded custom theme setting types (boolean, color, text, image). Site owners benefit from enhanced offer management with status tracking and redemption counting, while content creators will appreciate fixes to publishing workflow issues.
The release includes substantial internal refactoring, replacing the deprecated i18n package with tpl throughout the codebase and decoupling frontend routing from the URL service. These changes improve maintainability and set the foundation for future enhancements.
Performance monitoring has been enhanced with boot-time metrics and better email analytics debugging. The update also addresses several bugs, including issues with undismissable notification banners and Stripe Checkout integration.
Overall, this is a feature-rich release that improves both the developer and user experience without introducing breaking changes, making it a recommended upgrade for all Ghost installations.
Full Release Notes
- ✨ Added basic
{{match}} helper - Hannah Wolfe
- 🐛 Fixed incorrect publish type showing in publish menu after close/re-open - Kevin Ansfield
- 🐛 Fixed inability to re-schedule a scheduled post - Kevin Ansfield
View the changelogs for full details: