Skip to the content
Documentation
Help Start
Reading in:
  • German: 9,090 of 9,090 pages
About the help in other languages
All help pages

Checklist: code review for templates

What a reviewer checks in a template or stylesheet change: escaping, translations, fetches and caching, overrides, inline code, tokens and dark values, logical properties, accessibility, and the light and dark…

Download as PDF

Address: https://doc.exponential.earth/exphelp/viewer/help/designers/theme-design/checklist-code-review-for-templates.md

On this page

Checklist: code review for templates

This page is for reviewers of template and stylesheet changes, and for designers who want their change accepted at the first review. It follows the project's review list for admin templates and adds what applies to every design.

Contents

  1. Correctness and safety
  2. Performance
  3. Styling
  4. Accessibility and languages
  5. Evidence

Correctness and safety

  • To do: Every value from content, settings or the request is washed when printed (Wash and escaping).
  • To do: URLs built with ezurl/ezroot, design files with ezimage/ezdesign; no hard-coded siteaccess paths.
  • To do: Optional fields tested with has_content before use.
  • To do: {def} variables {undef}ined in included templates; no clash with the includer's names.
  • To do: Override rules: unique prefixed names, a correct Match, Priority where it matters (Override ordering).
  • To do: The template parses: ./console exp:eztemplatecheck <file or folder>.

Performance

  • To do: Every list fetch has a limit; no fetch in a loop (Fetch performance).
  • To do: Cache-block keys cover everything that changes the output, and nothing more.
  • To do: Nothing user-specific in a view-cached template; no csp_nonce() in cached output.

Styling

  • To do: No <style> and no style=""; no inline scripts or handlers (CSP-safe design).
  • To do: Shared classes reused (admin: .a4-* components) before new CSS.
  • To do: Only tokens for colors, radius, spacing, fonts; a dark value for every new color token.
  • To do: Module CSS in the right file (admin: stylesheets/modules/<group>.css or the extension's admin stylesheet).
  • To do: Logical properties instead of left and right.
  • To do: Stylesheet changes deployed with the packer step; no ?v= queries.

Accessibility and languages

  • To do: Every interface text through i18n with the right context, placeholders for variable parts.
  • To do: Headings in order; landmarks intact; buttons are buttons, links are links.
  • To do: Images have alt text; icon-only controls have names.
  • To do: Focus visible; keyboard works for anything interactive the change adds.

Evidence

  • To do: Screenshots of the changed page in light and dark mode, at 1440 px and at 960 px with scale 2.
  • To do: For admin designs: php vendor/bin/phpunit --testsuite design passes (The admin styling rules test).
  • To do: No console errors on the changed pages.

Become an Exponential Partner

Partners share their information, provide funding, contribute back and develop the products with us, and that is how Exponential grows. A partner website and dashboard are planned for mid-2027: please become a partner today to speed up our growth rate and land new features faster.

Something wrong on this page? Report an error

Documentation license

This documentation is free documentation, licensed under the GNU Free Documentation License 1.3 or later.

Exponential Copyright © 1998-2026 Exponential Foundation and 7x