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

RactiveJS causes issues with ESRI Dojo JSAPI library. #1093

Closed
donnyv opened this issue Aug 7, 2014 · 10 comments
Closed

RactiveJS causes issues with ESRI Dojo JSAPI library. #1093

donnyv opened this issue Aug 7, 2014 · 10 comments

Comments

@donnyv
Copy link

donnyv commented Aug 7, 2014

For some reason adding RactiveJS with ESRI's Dojo JSAPI library causes an error in the JSAPI library.
Just adding these 2 script tags causes an error.

<script src="http://js.arcgis.com/3.10compact/"></script>
<script src='http://cdn.ractivejs.org/latest/ractive.js'></script>

ESRI's JSAPI home page.
https://developers.arcgis.com/javascript/

@MartinKolarik
Copy link
Member

an error

Error message?

@donnyv
Copy link
Author

donnyv commented Aug 7, 2014

Its pretty big, so here is a snap shot.
capture

@martypdx
Copy link
Contributor

martypdx commented Aug 7, 2014

Looks like AMD issue (multipleDefine). What if you switch the order? That's what I try before I bail on AMD - haha.

@martypdx
Copy link
Contributor

martypdx commented Aug 7, 2014

That actually seems to work: http://jsbin.com/micoc/1/edit. :facepalm emoji:

@donnyv
Copy link
Author

donnyv commented Aug 7, 2014

That did it.

@martypdx
Copy link
Contributor

martypdx commented Aug 7, 2014

Now as long as you don't have to add a 3rd AMD library 🙈

@donnyv
Copy link
Author

donnyv commented Aug 7, 2014

ha!

@Rich-Harris
Copy link
Member

Yeah, looks like ArcGIS bundles an AMD module loader and leaves it lying around on the page to nuke everyone else's stuff! AFAICT this is equivalent to the Mismatched anonymous define module message you'd get if you put RequireJS on the page then subsequently loaded a library with a <script> tag rather than require()/define().

Is there a place to file that as an ArcGIS bug? I'll close this issue, since there's nothing Ractive could really be doing differently in this situation (note that it will still register itself as window.Ractive so it should continue working despite the error)

@donnyv
Copy link
Author

donnyv commented Aug 11, 2014

I couldn't find a place to file the bug. I found there product engineer on twitter and pointed him to this issue. https://twitter.com/derekswingley

@dmfenton
Copy link

Here's a solution to a related problem with Angular Esri/angular-esri-map#38 (comment)

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

No branches or pull requests

5 participants