Bug 39085

Summary: No space preserved incorrecly after END
Product: Koha Reporter: Jonathan Druart <jonathan.druart>
Component: Architecture, internals, and plumbingAssignee: Bugs List <koha-bugs>
Status: NEW --- QA Contact: Testopia <testopia>
Severity: enhancement    
Priority: P5 - low    
Version: unspecified   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:
Bug Depends on: 38664    
Bug Blocks:    

Description Jonathan Druart 2025-02-10 21:09:44 UTC
The prettier plugin cannot guess if the absence of space was needed, so it got preserved. However in some cases it's not needed.

Eg.
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/supplier.tt
+                        [% END %]</li
+                    >

We could move the closing li on a separate line for better indentation and readability.

Also the closing title almost everywhere:
-[% END %]</title>

If we don't want spaces we need to CHOMP


List the candidates with `git grep -P 'END %][^\s|>|;|)|"|[]' **/*.tt`