These are chat archives for bem/talk

19th
Aug 2014
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 05:02
Is strings in *Deps interpreted as blocks names?
Sergey Berezhnoy
@veged
Aug 19 2014 05:09
@floatdrop yes — there is a lot of shortcuts (right as we like)
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 05:10
This should be in docs as well :(
Alexej Yaroshevich
@zxqfox
Aug 19 2014 05:10
Actually, yes. But it's so intuitive...
Sergey Berezhnoy
@veged
Aug 19 2014 05:10
is it no yet
?
so please add issue
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 05:11
*didn't
Alexej Yaroshevich
@zxqfox
Aug 19 2014 05:12
Deps not so well documented. Especially depsByTech ;-)
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 05:12
I have another question - what will be if I have array in deps file, but elements in it did not have tech property?
Will they be merged?
Sergey Berezhnoy
@veged
Aug 19 2014 05:13
please add issue about depsByTech docs also ;-)
Alexej Yaroshevich
@zxqfox
Aug 19 2014 05:13
;-D
Sergey Berezhnoy
@veged
Aug 19 2014 05:13
@floatdrop yes, should be — why not?
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 05:14
because it is not clear from documentation?
Sergey Berezhnoy
@veged
Aug 19 2014 05:16
hmm... feel free to add issue about all docs lacks
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 05:19
here you go bem/bem-core#648
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 06:24
How often you are using deps of modificators values?
Alexej Yaroshevich
@zxqfox
Aug 19 2014 06:25
Never in my own blocks. Or I just don't know about it
Sergey Berezhnoy
@veged
Aug 19 2014 08:05
a lot! take a look at bem-components
and so on
Sergey Berezhnoy
@veged
Aug 19 2014 08:12
what special with this one?
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 08:12
this is deps for certain value of modificator
you listed only modificators deps
I thought you misunderstand me
Sergey Berezhnoy
@veged
Aug 19 2014 08:14
nope — I listed modifiers value too, just for boolean modifiers (which we introduce not so far)
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 08:20
so… this one common.blocks/i-bem/__dom/_init/i-bem__dom_init.deps.js should be treated as deps for i-bem__dom_init_true?
i-bem__dom with mods init: true?
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 08:26
where should I look about boolean modifiers in documentation?
ookay
I’m pretty sure, that boolean modifiers is wrong decision
on level of deps
or I misunderstand boolean modifier
Sergey Berezhnoy
@veged
Aug 19 2014 08:33
we keep i-bem__dom_init_auto witout boolean values
docs about boolean values for modifiers just combined in main docs : http://ru.bem.info/technology/i-bem/2.3.0/i-bem-js/
I can understand what exactly do you call "wrong decision" — could you please describe deeply?
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 08:38
it maybe not wrong, but confusing for sure
if I have midificator checkbox
which should have deps in both cases (true/false)
and I have elem_checkbox.deps.js
will it be applyed on false value of modificator?
Sergey Berezhnoy
@veged
Aug 19 2014 08:44
the nuance is that deps doesn't "apply" for concrete block instance, they affect content of builded bundle — so if you decl deps item_modname.deps.js they will be added for any occurrence of item_modname_*
the special case with boolean modifiers is that you only have modifier when you have 'true' value
and have no any modifiers in case of 'false'
thats why you can short item_modname_true.deps.js to just item_modname.deps.js
pretty as with html classes ;-)
we doesn't write item_modname_true, just item_modname
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 09:05
but what will be on modname: false
?
Sergey Berezhnoy
@veged
Aug 19 2014 09:06
you don't need to write this (cause
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 09:07
yes I need
Sergey Berezhnoy
@veged
Aug 19 2014 09:07
it's redundant)
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 09:07
for example I have modificator checkbox
Sergey Berezhnoy
@veged
Aug 19 2014 09:07
but if you — it's treated just like omitting mod
Vsevolod Strukchinsky
@floatdrop
Aug 19 2014 09:07
exactly
and checkbox false will not use themes and js
Sergey Berezhnoy
@veged
Aug 19 2014 09:08
if you have so
if you have some deps for true AND false values of some mode that's mean that you have such deps for block itself
Sergey Berezhnoy
@veged
Aug 19 2014 09:13
maybe that you call "wrong" about deps for mods itself in case of bool vals
yes — in case of bool vals there is little difference
Alexej Yaroshevich
@zxqfox
Aug 19 2014 15:18
Guys, Im refactoring express-bem. Can you give me some idea where to store https://github.com/zxqfox/express-bem/blob/master/lib/engines/complex.js ? Or maybe we just don't need this?
I'm thinking about some configured package to select what it should use. bemhtml or bh, which parameters to use (bemjson, raw), and so on. But I have troubles with naming. express-bem-bemfullstack ?