All you have to do after adding a new .less file to the project is right-clicking on the new inactivity file, and “Compile File” should be the only option by selecting this option, which will then be added to compilerconfig. json file. This will not lead to adding all files without changes to the project in the configuration with one click, but it will automatically add them with a quick click on each file, and you will not have to add them manually.
BEFORE:
[ { "outputFile": "less/site.css", "inputFile": "less/site.less" } ]
AFTER:
[ { "outputFile": "less/site.css", "inputFile": "less/site.less" }, { "outputFile": "less/theme.css", "inputFile": "less/theme.less" } ]
You can also recompile all files from the Task Explorer window. There you should see compilerconfig.json, below you will see “LESS”, you can “Run” to compile everything or select one file. You can also compile the assembly.
An alternative method would be to use the gulp file. You can configure the task to get fewer files in your project without thinking about it after setting it up.
source share