Skip to Content
Menu
This question has been flagged
1565 Views

Hello

I'm looking a solution to link a .scss file according to the value of a variable.
Ex:

<template id="assets_backend" name="my_managment_assets"
inherit_id="web.assets_backend">
<xpath expr="." position="inside">
<t t-set="mode" t-value="test"/>
<t t-log="self"/>

<link href="/my_module/static/src/scss/my_scss.scss" rel="stylesheet" type="text/scss"/>
        
        <t t-if="host=='test.my-server.com'">
    <link href="/my_module/static/src/scss/my_scss-test.scss" rel="stylesheet" type="text/scss"/>
        </t>


</xpath>
</template>
Avatar
Discard