Skip to content

style: use built-in askama profile in djlint - #620

Merged
m4tx merged 1 commit into
masterfrom
djlint-askama
Jul 20, 2026
Merged

m4tx merged 1 commit into
masterfrom
djlint-askama

Conversation

@m4tx

@m4tx m4tx commented Jul 20, 2026

Copy link
Copy Markdown
Member

Type of change

  • Bug fix
  • New feature
  • Documentation
  • Refactor / cleanup
  • Performance improvement
  • Other (describe above)

@m4tx
m4tx requested review from a team and Copilot July 20, 2026 19:18
@github-actions github-actions Bot added the C-lib Crate: cot (main library crate) label Jul 20, 2026

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the project’s HTML/template linting and formatting setup to use djLint’s built-in Askama profile (instead of the Jinja profile), and applies the resulting reformatting to a few Askama templates.

Changes:

  • Switch djLint configuration from profile = "jinja" to profile = "askama".
  • Bump the pre-commit djLint hook version to v1.42.0.
  • Reformat several templates to match the updated djLint/Askama formatting output (primarily whitespace/line wrapping changes).

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
cot/templates/fail.html Reflows a paragraph into a single line per the updated formatter/profile.
cot/templates/error.html Condenses {% match %} blocks to align with Askama profile formatting.
cot/templates/admin/model_edit.html Aligns block ending / indentation with formatter output for Askama templates.
.pre-commit-config.yaml Updates the djLint pre-commit hook to v1.42.0.
.config/djlint.toml Switches djLint profile to askama while keeping existing ignores.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions

Copy link
Copy Markdown

🐰 Bencher Report

Projectcot
Branchdjlint-askama
Testbedgithub-ubuntu-latest

🚨 1 Alert

BenchmarkMeasure
Units
ViewBenchmark Result
(Result Δ%)
Upper Boundary
(Limit %)
empty_router/empty_routerLatency
milliseconds (ms)
📈 plot
🚷 threshold
🚨 alert (🔔)
12.99 ms
(+80.53%)Baseline: 7.20 ms
12.44 ms
(104.42%)

Click to view all benchmark results
BenchmarkLatencyBenchmark Result
microseconds (µs)
(Result Δ%)
Upper Boundary
microseconds (µs)
(Limit %)
empty_router/empty_router📈 view plot
🚷 view threshold
🚨 view alert (🔔)
12,994.00 µs
(+80.53%)Baseline: 7,197.60 µs
12,444.13 µs
(104.42%)

json_api/json_api📈 view plot
🚷 view threshold
1,093.70 µs
(+0.77%)Baseline: 1,085.34 µs
1,356.58 µs
(80.62%)
nested_routers/nested_routers📈 view plot
🚷 view threshold
1,027.40 µs
(+1.71%)Baseline: 1,010.17 µs
1,234.37 µs
(83.23%)
single_root_route/single_root_route📈 view plot
🚷 view threshold
981.72 µs
(+0.86%)Baseline: 973.36 µs
1,197.97 µs
(81.95%)
single_root_route_burst/single_root_route_burst📈 view plot
🚷 view threshold
17,238.00 µs
(-1.13%)Baseline: 17,435.47 µs
21,528.99 µs
(80.07%)
🐰 View full continuous benchmarking report in Bencher

@codecov

codecov Bot commented Jul 20, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

Flag Coverage Δ
rust 90.25% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@m4tx
m4tx merged commit ce7be75 into master Jul 20, 2026
42 of 43 checks passed
@m4tx
m4tx deleted the djlint-askama branch July 20, 2026 20:35
@cotbot cotbot Bot mentioned this pull request Jul 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

C-lib Crate: cot (main library crate)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants