Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

page: Use must-dependency on i-bem-dom__init_auto #1395

Closed
tadatuta opened this issue Jul 31, 2016 · 5 comments
Closed

page: Use must-dependency on i-bem-dom__init_auto #1395

tadatuta opened this issue Jul 31, 2016 · 5 comments
Assignees
Milestone

Comments

@tadatuta
Copy link
Member

Otherwise code in page.js won't be called on page load.

@narqo
Copy link
Member

narqo commented Sep 16, 2016

it should be a dependency on i-bem-dom in page.deps.js on the level where you introduce page.js file

@tadatuta
Copy link
Member Author

@tadatuta tadatuta reopened this Sep 16, 2016
@narqo
Copy link
Member

narqo commented Sep 16, 2016

Because our API sucks™.

An i-bem__dom_init_auto dependency has been added after tonnes of complaints from Yandex users, for whom the need for this dependency was not obvious. The dependency was introduced as a standard case solver.

The "must-deps" dependency on i-bem-dom is needed only when page has it's own JavaScript, and it's not what we have in bem-core or any of "average library".

@tadatuta
Copy link
Member Author

I have at least 5 bug reports about it. Why can't we just change it to must? What drawbacks it has?

@tadatuta
Copy link
Member Author

Decided to force users to add mustDeps on i-bem-dom on their own level and not to introduce it in bem-core.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants