Skip to content

Commit

Permalink
[BUGFIX] Fix the asset paths in single HTMl
Browse files Browse the repository at this point in the history
And add an integration test for single HTML.

It was until now not possible testing it.

There are still open issues with single HTMl, but I would suggest to solve them in follow-ups.

- TYPO3-Documentation/render-guides#238
- TYPO3-Documentation/render-guides#239

Resolves TYPO3-Documentation/render-guides#233
  • Loading branch information
linawolf committed Dec 26, 2023
1 parent 6b2b61d commit 3efe95b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 3 additions & 1 deletion resources/template/structure/singlepage.html.twig
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
{% block body %}
<!-- content start -->
{% for document in documents -%}
{{ renderNode(document) }}
<article>
{{ renderNode(document) }}
</article>
{%~ endfor -%}
<!-- content end -->
{% endblock %}
1 change: 1 addition & 0 deletions src/Twig/TwigExtension.php
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ public function getCurrentFilename(array $context): string
*/
public function getRelativePath(array $context, string $path): string
{
$renderContext = $this->getRenderContext($context);
if ($this->typo3AzureEdgeURI !== '') {
// CI (GitHub Actions) gets special treatment, then we use a fixed URI for assets.
// TODO: Fixate the "_resources" string as a class/config constant, not hardcoded
Expand Down

0 comments on commit 3efe95b

Please sign in to comment.