Skip to content

Initial attempt at AMD support#99

Closed
lboynton wants to merge 12 commits intometajack:masterfrom
lboynton:amd
Closed

Initial attempt at AMD support#99
lboynton wants to merge 12 commits intometajack:masterfrom
lboynton:amd

Conversation

@lboynton
Copy link
Copy Markdown
Contributor

This is my initial attempt at AMD support for issue #66, with supporting tests. I've made some compromises to make the diff smaller. Ideally, the source files should be renamed to match the module name (ie Base64.js instead of base64.js) so that you don't need the path mapping in requirejs.config. I've also added an example using AMD.

I will squash the commits before merging once getting some feedback.

@lboynton
Copy link
Copy Markdown
Contributor Author

lboynton commented Dec 3, 2012

Should Strophe still define window globals even if AMD is used? There are a lot of Strophe plugins which expect globals. I've found that using the shim config in require.js is unreliable for Strophe plugins which expect the Strophe global. The amdWebGlobal.js below defines a global even if AMD is being used.

https://github.com/umdjs/umd/blob/master/amdWeb.js
https://github.com/umdjs/umd/blob/master/amdWebGlobal.js

@jfmoy
Copy link
Copy Markdown

jfmoy commented Jan 9, 2013

A quick message to show my support to the initiative, I hope soon Strophe will be AMD ready.

@lboynton lboynton closed this Dec 8, 2014
Gordin pushed a commit to Gordin/strophejs that referenced this pull request Jan 31, 2015
escapeNode & unescapeNode null tolerance
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

Successfully merging this pull request may close these issues.

3 participants