-
Notifications
You must be signed in to change notification settings - Fork 9.4k
problems with jquery plugins #1034
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
Comments
You should use data-mage-init attribute on your widget node to initialize your camera widget. Its source file will be automatically loaded by requirejs. (see http://devdocs.magento.com/guides/v1.0/frontend-dev-guide/javascript/js-mage-plugin.html#fedg_js-mage_widgets_dataattrib) To make your widget load after jquery, declare jquery as a dependency in your widget (http://requirejs.org/docs/api.html#funcmodule) |
@Antonioele, did @antonkril comment solve your problem? |
@vpelipenko , I solve my problem with the help of antonkril , using requirejs , sorry if I insist, it is not advisable to use the layout to load jquery plugins, it would be comfortable as in magento 1.9. |
@Antonioele, due to last changes in the framework, it is strongly recommended now to use requirejs to load any js plugins. |
@Antonioele, do you have other questions about plugins? if no, can we assume this issue resolved? |
@Antonioele, this issue will be closed. I hope we've helped you to resolve your problem. If you have any other problems or questions about jquery plugins, feel free to reopen this issue or create new one. |
[FearlessKiwis] MAGETWO-31891: Changes made in tax configuration are not seen in backend...
[Firedrakes] MAGETWO-67477: Add @api annotation to Sales module
Magento The version is 0.42.0-beta7 with sample data
in luma/Magento_Theme/layout I have insert file default_head_blocks.xml :
in the head I have insert
1° problem :
camera.js there is in pub/static/frontend/Magento/luma/it_IT
I see whith firebug
some times load camera.js at other times do not.
problem layout magento and requirejs ??????????
2° problem
I have create block camera with widget camera
but some times when I call camera plugin I have this problem: jquery not found
magento load first camera.js or block camera and after jquery.
The text was updated successfully, but these errors were encountered: