TL;DR
Ghost 3.14.0 introduces significant improvements to the email experience for members, including a new Email card for content that only appears in emails, timezone-aware email dates, and enhanced public API endpoints for members.js integration. This release also includes numerous code refactoring changes to improve the internal architecture, making middleware more modular and easier to maintain.
Highlight of the Release
- New Email card for creating email-only content
- Fixed timezone handling in email publish dates
- Enhanced public API endpoints for members.js integration
- Extensive middleware refactoring for better code organization
- Fixed admin host with port infinite redirect issue
Migration Guide
No migration steps are required for this release. The changes are primarily internal refactoring and feature additions that don't require any action from users or developers.
Upgrade Recommendations
This release is recommended for all Ghost users, especially those who use the email newsletter functionality. The improvements to email content handling and timezone support will provide a better experience for both content creators and newsletter recipients. The code refactoring also improves the overall stability and maintainability of the platform.
Bug Fixes
Fixed Timezone Issues in Email Publish Dates
Email publish dates now correctly respect the site's configured timezone instead of defaulting to UTC, ensuring that dates displayed in emails match the site's settings.
Fixed Admin Host with Port Causing Infinite Redirect
Resolved an issue where setting a different admin host with a port would cause an infinite redirect loop. The code now properly compares host values and uses the correct trusted, requested value.
Fixed Public/Members.js Request Path
Removed a trailing slash typo in the public/members.js request path that was causing issues with loading the members script.
Fixed Member First Name in Session Data
Corrected a bug in how a member's first name is calculated when retrieving member session data in themes.
Fixed Default Scheduler Timeout
Added a check for the existence of timeoutInMS before using it in the default scheduler, ensuring the fallback of 5000ms is used when needed.
New Features
New Email Card
A new Email card has been added to the editor, allowing content creators to insert content that only appears when posts are emailed to members. This provides greater flexibility in crafting email-specific messaging without affecting the web version of posts.
Enhanced Public API Endpoints
The public site endpoint now includes additional data such as site description, logo, brand, and member settings like plans and self-signup options. This provides richer data for the members.js script and other integrations.
Member Session Data Exposure
A new endpoint (/members/ssr/member) has been added to expose member session data on the site, enabling members.js to load member data when they are logged in. This uses the same logic and data that is passed to themes through handlebar helpers.
Security Updates
No significant security fixes were included in this release.
Performance Improvements
Code Structure Improvements
Numerous middleware components have been moved from shared locations to their specific app contexts (site, parent, API), improving code organization and making the codebase more maintainable. This refactoring makes it easier to understand which middleware is used where and reduces unnecessary coupling between components.
Simplified Redirect Logic
The redirect code has been refactored using destructuring to make it more readable and maintainable, with clearer variable naming and more explicit comparisons.
Impact Summary
Ghost 3.14.0 focuses on enhancing the email experience with the new Email card feature and fixing timezone-related issues in email publish dates. It also includes significant internal code refactoring to improve the organization of middleware components, making the codebase more maintainable.
For content creators, the Email card provides new flexibility in crafting email-specific content. For developers, the enhanced public API endpoints and member session data exposure offer more options for custom integrations. The fixed admin host with port issue resolves a frustrating redirect loop problem for administrators using custom configurations.
While most of the changes are under the hood, they collectively contribute to a more robust and flexible platform, particularly for sites that make heavy use of the membership and newsletter features.
Full Release Notes
- ✨ Added "Email" card for inserting content that only appears when emailing posts to members - Kevin Ansfield
- ✨ Added description and logo to admin/site endpoint - Rish
- 💄 Added reset behavior for test email newsletter button - Rish
- 🐛 Fixed ability to schedule emailed post when date is incorrect - Kevin Ansfield
- 🐛 Fixed public/members.js request path - Hannah Wolfe
- 🐛 Fixed publish date in emails not respecting site's configured timezone - Kevin Ansfield
See the changelogs for Ghost and Ghost-Admin for the details of every change in this release.