-
-
Notifications
You must be signed in to change notification settings - Fork 329
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
is_a? and kind_of? not working on an Array when two opal generated js are included (Chrome 33-39) #616
Comments
A simple test case. Opal file:
|
Out of interest, what is the normal way to have multiple independant Opal generated js files only include the single Opal runtime? |
State in the
|
I'll add a check in the runtime to avoid loading it twice |
Can you try on master please? |
@meh same on master, the above test produces:
|
Extending the test a bit...
Gives me:
|
Thanks, that cleared up whatever was happening underneath |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I have an array that is having a bit of an identity crisis when the class lookup is done from within a callback and there is a second javascript generated from ruby with
require 'opal'
included in the page.Results in:
It's been hard to create a simple test case to post reproducing the issue, very similar code in a separate script delivered out of the same Sinatra web app produces the correct results. I'm not intentionally messing with the
Array
class anywhere so I'm at a loss as to where it's coming from.I can see what the issue is though, the class comparison is failing due to the passed in class
Array
which ends up being$opal.cm('Array')
in the javascript does not include a_full_name
property that the original object/selfOpalClass
includes.Includes:
Versions:
The text was updated successfully, but these errors were encountered: