npm install
src/blocks
- папка bem
src/blocks/pages
- страницы
src/blocks/sections
- общие блоки страниц header, footer, about
и тд.
src/blocks/modules
- блоки выводимые в sections
src/blocks/components
- компоненты на подобии card, alert
- pages
- head
- sections
- modules
- components
- components
- modules
.pug
.scss
.js
.json
bem create my-block
bem create me-block -l folder/folder
или
npm run create:bem
- В
dev
режиме собриются 2 разных файлаtheme.css
иsystem.css
, это сделано чтобы не тратить лвиную долю времени на компиляцию редко изменяемых библиотек. - В
production
режиме все стили объединяются в один файлapp.css
Все сторонние большие библиотеки скриптов копируются из node_modules
в минимизированном виде
Свои скрипты и скрипты маленького размера подключаются
- в файле
js/entry.js
- или из папки
js/concat
и компилируетсяwebpack
- Разделить сборку библиотек
- Добавить активную менюшку страницы
- tableThName