Commit 4bc3e3e1 authored by Nikolay Gromov's avatar Nikolay Gromov

Багфикс: не-pug-файлы сторонних блоков не брались в сборку

parent 9cdc3f67
...@@ -37,7 +37,7 @@ const path = require('path'); ...@@ -37,7 +37,7 @@ const path = require('path');
const buildLibrary = process.env.BUILD_LIBRARY == 'yes' ? true : false; const buildLibrary = process.env.BUILD_LIBRARY == 'yes' ? true : false;
const nth = {}; const nth = {};
nth.config = require('./config.js'); nth.config = require('./config.js');
nth.blocksFromHtml = []; // блоки из HTML (только если имеют свою папку блока!) nth.blocksFromHtml = nth.config.alwaysAddBlocks; // блоки из конфига сразу добавим в список блоков
nth.scssImportsList = []; // список импортов стилей nth.scssImportsList = []; // список импортов стилей
const dir = nth.config.dir; const dir = nth.config.dir;
...@@ -467,7 +467,7 @@ function getClassesToBlocksList(file, enc, cb) { ...@@ -467,7 +467,7 @@ function getClassesToBlocksList(file, enc, cb) {
if (processThisFile) { if (processThisFile) {
const fileContent = file.contents.toString(); const fileContent = file.contents.toString();
let classesInFile = getClassesFromHtml(fileContent); let classesInFile = getClassesFromHtml(fileContent);
nth.blocksFromHtml = []; // nth.blocksFromHtml = [];
// Обойдём найденные классы // Обойдём найденные классы
for (let item of classesInFile) { for (let item of classesInFile) {
// Не Блок или этот Блок уже присутствует? // Не Блок или этот Блок уже присутствует?
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment