I’ve built a theme for myself, based on bits from various themes, including Sage. Specifically, I’m using the webpack stuff from Sage 9. However, I’m stuck using Bootstrap 3 and LESS files.
I’m also using an “atomic” approach where I’m using a file-structure that breaks out TWIG templates, ACF “model” definition PHP files and LESS files into the typical atom/molecule/organism/page approach that, say, PatternLab uses. It’s all looking quite nice.
However, a webpack issue I can’t sort out…
I am using globby (npm module) to scan the filesystem for LESS files, rather than have them @imported from a master LESS file. It ends up with a very long JSON array in entry -> main in config.json.
However, it won’t compile! I’m making sure to put the variable definition LESS files first in the compile, but they’re not being included properly. So later LESS files crash because their variables are not defined.
Does anyone know why the LESS compiler wouldn’t be able to interpret properly when the LESS files are listed in this way, as a long array, rather than @imported in one master file, as is done with Sage 9, presently?!
I know this is a bit obscure, but I feel like this should not be a problem!