-
Notifications
You must be signed in to change notification settings - Fork 14
TreeView: Including dependency for 'gallery-itsatoolbar' causes error. #29
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
Yep, you should contact the author of gallery-itsatoolbar. |
Hey Ryan, As creator of itsatoolbar, I dived into this, but the issue is not purely this module and seems far more complex. As far as I can see, it is the loader that causes this. If so, than it goes beyond my knowledge. This is what I found out:
I hope it makes sense and you can reproduce the issue. |
Thinking more about it: It might as well be the order of loading the modules. That is, it could be that the error only occurs if "widget" is loaded after gallery-sm-treeview. If I manually use YUI.add(), then it is loaded before. |
@ItsAsbreuk Thanks for digging in! I'm pretty busy with work right now, but I'll investigate as soon as I have time. This does sound like something weird in Loader. |
You're welcome. As far as I can see at this moment it is the order of loading the modules. The error-example puts the widgets-modules almost at the bottom: after 'tree' and before 'gallery-sm-tree'. Whereas the working examples have 'widget' loaded before 'tree'. Perhaps you'll find Y.Widget to insert extra items in nodeExtensions[] after Tree is initialized, because it error on line https://github.com/yui/yui3/blob/master/build/tree/tree-debug.js#L761, saying 'nodeExtentions[i]' is undefined. Anyway, good luck. Marco. |
Hi there,
I have 2 test files, one (which functions as expected) with these dependencies declared in the use() method: ['gallery-sm-treeview','gallery-sm-tree-lazy','editor'].
http://codefinger.co.nz/public/yui/yui-editor-treeview/index2.html
The other test file is basically the same, but has the 'gallery-itsatoolbar' as an additional dependency:
http://codefinger.co.nz/public/yui/yui-editor-treeview/index.html
With the second test file, I get this error in Chrome inspector:
Uncaught TypeError: Cannot read property 'prototype' of undefined tree.js:743
So I'm unsure which module is causing the error, though the error is in tree.js, I might need to submit an issue with the creator of 'gallery-itsatoolbar', but I don't know sorry.
The text was updated successfully, but these errors were encountered: