I have a TWIG code to display the address of a store.
Currently the address is rendered on 3 lines.
How to make the address code on one line ?
{{ store.address|render|trim|replace({'<br>': ' - '})|striptags|raw }}
I have a TWIG code to display the address of a store.
Currently the address is rendered on 3 lines.
How to make the address code on one line ?
{{ store.address|render|trim|replace({'<br>': ' - '})|striptags|raw }}

Your are outputting the address inside a
<pre>tag. Thewhite-spaceof the<pre>tag is set topreby default. See here for more information about this.So you have 2 options
<pre>tag with a<div>white-spaceof the<pre>withcss