kotlin extensions
# android
a
kotlin extensions
m
aris: hello
android extensions works great, so there’s no need to use butterknife
the only case i see is in custom viewgroups, in which the plugin doesnt work. in that case, you can do it by hand(findViewById), or use Butterknife
a
it’s a bug?
m
no, dont think it is
well
you can use it, but it will only generate a findViewbyId in every place you use it
so not very efficient
my advice, use in in activity, fragment and dialogs. use findViewById in custom viewgroupd
and when u need to call a view multiple times in row, for example recyclerview
to initiate adapter, layoutmanager, decorators etc. do it like this: rv.run{} and do the stuff inside it
the plugin is good but it generates a cast everytime you access a view. thats the only thing i dislike. appart form that, amazing
a
Okey, perfect. Thx!