E
E
evilelf2016-03-11 13:29:04
Pug
evilelf, 2016-03-11 13:29:04

How to use BEM+JADE+GULP?

Hello.
I think it's more convenient to use bam with jade.
I dug up such a module https://github.com/ideyuta/nbem
But I can't put it in gulp.
The idea is great, it would be the whole methodology on the machine.
What are similar things?

Answer the question

In order to leave comments, you need to log in

6 answer(s)
L
lavezzi1, 2016-03-11
@evilelf

https://github.com/admdh/adm-dev-kit-gulp
https://github.com/tars/tars
cpt.csssr.ru
All builds work in a similar way as the BEM stack. Some of them even have dependencies.
PS But I would not advise.

K
Konstantin Velichko, 2016-03-24
@Zoxon

Boilerplate for jade, stylus and BEM https://github.com/zoxon/gulp-front
There is also a good library of mixins https://github.com/kizu/bemto but this is not for everyone

C
Cat Scientist, 2016-08-11
@eruditecat

Try it:

const pug = require('pug');
const pbem = require('pbem');

const scope = pbem({
  blocksDir: __dirname + 'views/blocks'
}).precompile();

const separateTemplate = pug.compileFile(__dirname + 'views/page.pug');

let renderedSeparateTemplate = separateTemplate({
  block: scope.createBlock
});

In templates:
index.pug:
blocks/block-name/block-name.pug:
div&attributes( attributes() )
!= element('element-name').local('varName', varName)

https://github.com/bigslycat/pbem

F
FanatPHP, 2014-12-28
@FanatPHP

Hire someone on freelansim.ru
It will not cost too much, and - most importantly - you will not regret it later.
What you are doing now is terrible.
And even if some well-wisher does an invite check, it will not make your code better.

S
Svyatoslav, 2014-12-28
@SoulGear

You also need to delete the code \ put a flag that the code has been used.

S
Stanislav, 2014-12-28
@mzcoding

Rewrite it all and switch to PDO.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question