1 min read
bem-core library goes futher and there already is
available. This blog was safely switched to the new major version with
some diff to the
Now so can do you. Careful examination of the version changelog will help you
with it. Look how I did this.
When a new bem library version is released its changelog is published on the official BEM website. You can examine the list of changes for bem-core 2.0.0.
The changelog is divided into 3 parts: breaking, marjor and minor changes.
Breaking changes takes most of your attention. As you can see, they declare removing of some basic methods as well as hosting some code in different repositories. Thus, if you used some of the listed methods, the switch pushes you to refactor your code a little bit.
The same goes for the change to DOM helpers. With getting the context as a result of using those helpers you can get rid of a couple of lines per block.
Summing it up, switcing to the new version should be your happiest time as you have a ready-made excuse to dive into refactoring.