Skip to content

Conversation

@httpdss
Copy link
Owner

@httpdss httpdss commented Aug 12, 2025

This PR implements issue #95: Template ergonomics and power.

Changes

  • Globals: uuid(), now(), env(name, default), read_file(path)
  • Filters: to_yaml/from_yaml, to_json/from_json
  • Wiring: Registered helpers in template environment
  • Docs: Prominently document custom delimiters and add examples for new helpers
  • Tests: Existing suite passes (95 tests)

Acceptance criteria

  • New helpers are available in templates and documented

Closes #95

…yaml/from_yaml, to_json/from_json filters; document custom delimiters and new helpers (closes #95)
@codecov
Copy link

codecov bot commented Aug 12, 2025

Codecov Report

❌ Patch coverage is 70.21277% with 14 lines in your changes missing coverage. Please review.
✅ Project coverage is 65.44%. Comparing base (9b67a92) to head (f6a8d26).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
struct_module/filters.py 78.37% 8 Missing ⚠️
struct_module/template_renderer.py 40.00% 3 Missing and 3 partials ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #105      +/-   ##
==========================================
+ Coverage   65.06%   65.44%   +0.37%     
==========================================
  Files          18       18              
  Lines        1251     1285      +34     
  Branches      223      223              
==========================================
+ Hits          814      841      +27     
- Misses        372      379       +7     
  Partials       65       65              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@httpdss httpdss added minor enhancement New feature or request labels Aug 12, 2025
@httpdss httpdss merged commit d7c056a into main Aug 12, 2025
5 checks passed
@httpdss httpdss deleted the feature/95-template-helpers branch August 12, 2025 01:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request feature minor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Template ergonomics and power

2 participants