Switch to Hypertext #7

Merged
vanhouc merged 1 commit from feature/hypertext into main 2025-09-09 10:56:22 -04:00
vanhouc commented 2025-09-09 10:56:09 -04:00 (Migrated from github.com)

This pull request updates dependencies and refactors the codebase to replace the maud templating engine with the new hypertext crate for HTML rendering. It also improves dependency versioning and cleans up imports and usage patterns for several libraries.

Dependency and templating refactor:

  • Replaced maud with hypertext for HTML templating throughout the codebase, updating all usages and imports accordingly (src/cameron.rs, src/main.rs). [1] [2] [3] [4]
  • Added the hypertext dependency with axum feature, and removed the maud dependency from Cargo.toml.

Dependency version updates and cleanup:

  • Updated several dependencies in Cargo.toml to use less restrictive or more consistent version numbers (e.g., anyhow, fastrace-opentelemetry, logforth, opentelemetry, etc.).
  • Updated usage of dotenv to dotenvy, and improved error logging for environment loading in main.rs.

Axum and middleware improvements:

  • Updated references to middleware and layers (e.g., FastraceLayer, ServeDir, LiveReloadLayer) to use direct crate paths instead of importing at the top, improving clarity and reducing import clutter.
  • Updated the initialization of the OpenTelemetry reporter to use the fully qualified path for clarity.
This pull request updates dependencies and refactors the codebase to replace the `maud` templating engine with the new `hypertext` crate for HTML rendering. It also improves dependency versioning and cleans up imports and usage patterns for several libraries. **Dependency and templating refactor:** * Replaced `maud` with `hypertext` for HTML templating throughout the codebase, updating all usages and imports accordingly (`src/cameron.rs`, `src/main.rs`). [[1]](diffhunk://#diff-49d5dfca1bce8c7e5d388ac95be4ea7bdf7a12a969a7ef0f12f5b8cd8a629741L2-R23) [[2]](diffhunk://#diff-42cb6807ad74b3e201c5a7ca98b911c5fa08380e942be6e4ac5807f8377f87fcL6-R20) [[3]](diffhunk://#diff-42cb6807ad74b3e201c5a7ca98b911c5fa08380e942be6e4ac5807f8377f87fcL86-R80) [[4]](diffhunk://#diff-42cb6807ad74b3e201c5a7ca98b911c5fa08380e942be6e4ac5807f8377f87fcL103-R96) * Added the `hypertext` dependency with `axum` feature, and removed the `maud` dependency from `Cargo.toml`. **Dependency version updates and cleanup:** * Updated several dependencies in `Cargo.toml` to use less restrictive or more consistent version numbers (e.g., `anyhow`, `fastrace-opentelemetry`, `logforth`, `opentelemetry`, etc.). * Updated usage of `dotenv` to `dotenvy`, and improved error logging for environment loading in `main.rs`. **Axum and middleware improvements:** * Updated references to middleware and layers (e.g., `FastraceLayer`, `ServeDir`, `LiveReloadLayer`) to use direct crate paths instead of importing at the top, improving clarity and reducing import clutter. * Updated the initialization of the OpenTelemetry reporter to use the fully qualified path for clarity.
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
cameron/website!7
No description provided.