Coralite v0.23.0 Released
I am excited to announce the release of Coralite v0.23.0! This update introduces a powerful new plugin hook for interacting with rendered pages, refines attribute handling for slot components, and includes several bug fixes and type definition improvements.
The onAfterPageRender Plugin Hook #
We've introduced the onAfterPageRender plugin hook, which is executed right after a page has been fully rendered and its HTML string is ready. This provides an excellent entry point for generating sitemaps, RSS feeds, or modifying the final HTML output.
For instance, the new coralite-plugin-translation utilizes this hook to process translations on the final rendered output.
Bug Fixes & Refactoring #
This release also brings several under-the-hood improvements to make your Coralite experience smoother:
- Fully Merged Token Results: We now pass fully merged results to token functions and processors, ensuring consistent data availability.
- Slot Cloning Fix: Slot references are now correctly updated when cloning nodes, preventing issues during mutations.
- URL Updates: The homepage URL has been updated from
.ioto.devacross the project. - Type Reorganization: Type definitions have been reorganized by domain, making them easier to navigate and maintain. We've also added explicit type definitions for the Coralite plugin system!
How to Upgrade #
To upgrade to the latest version, update your project dependencies:
npm install coralite@0.23.0
npm install coralite-scripts@0.23.0
