I want to add a variable that located in "web/css/source/_theme.less
" to my custom less file, that I created specialy for home page. I added my less file in "Magento_CMS/layout/cms_index_index.xml
"
<?xml version="1.0"?>
<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:framework:View/Layout/etc/page_configuration.xsd">
<head>
<css src="css/home.css" />
</head>
</page>
In this home file i wrote
@baseDir: '../';
@import 'source/_theme.less';
@import 'source/_home.less';
but it doesn't import variable from "_theme.less
" to my "_home.less
" file.