TL;DR
Strapi v5.0.0-alpha.2: Major Helper Plugin Refactoring and Content Manager Fixes
This alpha release continues the v5 development with significant refactoring of the helper-plugin package, removing and relocating several utility hooks and functions. It also includes important fixes for Content Manager relation handling and makes the i18n plugin a required dependency. These changes are part of Strapi's ongoing efforts to streamline the codebase and improve the developer experience for v5.
Highlight of the Release
- Major refactoring of the helper-plugin package with removal of several utility hooks
- Fixed critical bugs in Content Manager relation handling
- Made i18n plugin a required dependency
- Improved integration between draft/publish and content releases features
- Enhanced data refetching in Content Type Builder after save or update operations
Migration Guide
Helper Plugin Breaking Changes
If you're a plugin developer using any of the following utilities from the helper-plugin package, you'll need to update your code:
Removed Utilities
useLockScroll
useClipboard
useFocusWhenNavigate
useQuery
useFocusInputField
useSelectionState
prefixPluginTranslations
stopPropagation and onRowClick utilities
Relocated Utilities
getFetchClient and useFetchClient have been moved to the admin package
useQueryParams has been relocated
Required Plugin
- The i18n plugin is now a required dependency
To migrate your code:
- Replace removed utilities with alternative implementations
- Update import paths for relocated functions
- Ensure your project includes the i18n plugin as a dependency
Upgrade Recommendations
As this is an alpha release (v5.0.0-alpha.2), it is primarily intended for testing and evaluation purposes. We recommend:
- Plugin Developers: Begin adapting your plugins to the breaking changes in the helper-plugin package to prepare for Strapi v5.
- Production Environments: Continue using stable Strapi v4 releases for production environments.
- Testing Environments: Consider setting up a separate testing environment to evaluate the alpha release and provide feedback to the Strapi team.
- Documentation: Review the migration guide and keep an eye on the official Strapi v5 documentation as it evolves.
This alpha release contains significant breaking changes, particularly for plugin developers, so thorough testing is essential before considering any production use.
Bug Fixes
Content Manager Relation Fixes
Several critical bugs related to relation handling in the Content Manager have been addressed:
- Fixed issues with sending status and locale information with disconnect arrays
- Resolved problems with relation caching when switching between tabs
- Fixed locale handling when the target entity is not localized
- Improved connection handling using proper ID references
Content Type Builder Data Refetching
Fixed an issue where the Content Type Builder wasn't properly refetching data after save or update operations, ensuring that the UI always displays the most current information.
New Features
Disabled Draft/Publish with Content Releases
The release introduces integration between the draft/publish feature and content releases. This enhancement improves the content workflow management capabilities of Strapi, allowing for better control over content publication processes.
I18n Plugin Now Required
The internationalization (i18n) plugin is now a required dependency in Strapi v5. This change ensures that all Strapi installations have consistent localization capabilities, providing a more standardized approach to multilingual content management.
Security Updates
No specific security fixes were included in this alpha release.
Performance Improvements
Improved Caching for Relations
The release includes optimizations for relation handling in the Content Manager, particularly addressing caching issues when switching between tabs. This improvement helps maintain consistent performance when working with related content.
Impact Summary
This alpha release represents a significant step in Strapi's v5 development journey, focusing on refactoring core utilities and improving content management functionality.
The most impactful changes are the breaking changes to the helper-plugin package, which will require plugin developers to update their code. The removal and relocation of several utility hooks and functions aims to streamline the codebase and improve maintainability, but will necessitate migration efforts for plugin developers.
Content managers will benefit from the fixes to relation handling in the Content Manager, addressing issues that could cause inconsistent behavior when working with related content. The improved integration between draft/publish and content releases features enhances Strapi's content workflow capabilities.
Making the i18n plugin a required dependency standardizes the approach to internationalization across all Strapi installations, ensuring consistent localization capabilities.
As an alpha release, these changes provide a preview of Strapi v5's direction, emphasizing code quality, developer experience, and robust content management features.