Release

Coralite v0.2.0

Discover Coralite v0.2.0 updates, including improved HTML parsing, page aggregation support, and enhanced JSDoc documentation for better developer experience.

TD
Thomas David January 23, 2025

Coralite’s latest release of its HTML module static site generator introduces significant improvements in processing structured data, component architecture, and developer tooling. This update replaces legacy regex-based parsing with HTML-centric methods, enhances module handling for complex components, and improves documentation across the codebase.

Core Functionality

The release prioritises robustness in document processing by shifting from regex to dedicated HTML parsing. This change enables more accurate extraction of metadata and structured content while supporting advanced features such as non-recursive requests in getHTML, page aggregation, and improved slot handling for component rendering.

  • Replaced regex-based parsing with HTML-centric methods to enhance compatibility with complex document structures. This improves reliability when processing nested or dynamic content.
  • getHTML now supports non-recursive requests by default, simplifying integration for use cases requiring targeted data extraction without deep traversal.
  • Introduced page aggregation functionality to dynamically combine metadata from multiple sources, expanding Coralite’s capabilities in content management and analysis workflows.
  • Rewrote module parsing logic to support ES modules and slot-based component creation. This enables more flexible rendering of reusable components with dynamic slots.

Code Improvements and Documentation

The update includes extensive updates to JSDoc comments across core functions, ensuring clarity for developers working with Coralite’s APIs. Specific improvements include:

  • Detailed documentation for parseModule, createComponent, and getHTML, with example usage scenarios added to clarify implementation details.
  • Refactored code organisation, including the relocation of HTML module functions into a dedicated html-modules.js file for improved maintainability.
  • Removed deprecated files and legacy features to streamline the codebase and reduce maintenance overhead.

Build and Configuration Updates

The release updates build configurations to target ES2022, ensuring compatibility with modern JavaScript environments. A dedicated executable file is now used for CLI operations, alongside updated package.json dependencies for HTML parsing and other enhancements.

Get the release

bash
Code copied!
  npm install coralite@0.2.0

For detailed information on all changes, refer to the git v0.2.0 changelog

TD

Thomas David

Creator of Coralite. Writing about the intersection of native web APIs, compiler design, and AI-assisted development.