linkedin/inject — pull request #129 by Jakobo (2012-06-15 20:46:30+00:00)
Title: Change from Porthole to EasyXDM

What we're getting with this switch.

1. easyXDM is a bit more tested and therefore reliable (Latest MS changes break Porthole in weird incompatible ways)
2. Setup is easier. Place *both* `relay.html` and `relay.html` on your alternate domain. This means `relay.html` doesn't have to have the weird dual-mode issue anymore
3. Refactored API. To simplify setup, all the API changes from #127 have been folded in. This internalizes many of Inject's proprietary things (to the `Inject.INTERNAL` namespace) leaving `Inject.*` free for configuring inject. This also frees up `require`, leaving it to supply only the compliant APIs for CommonJS and AMD.

What we're giving up.
1. a 12k increase in payload. This makes the library begin to feel very heavy. This will increase the need for us to solve "plugins" per #90 to keep things fast. We should also consider modifying the default build to produce a inject.lite.js/inject.lite.min.js which doesn't have the cross domain weight.
* old: 30,883 bytes (33 KB on disk)
* new: 42,403 bytes (45 KB on disk)
2. Simplicity in the Cross Domain interaction. easyXDM is *hard* that said, it's really well supported, and LinkedIn is already using it on the developer.linkedin.com properties without much issue. The code is easy to follow and the API has been incredibly stable for some time. Right now, we're using the simple socket method although we could also do RPC if we want to do that refactor at a later time.

Overall, I think this is a healthy change for the framework. Random IE breakages are not something we really want to be dealing with; that makes picking the juggernaut library a bit more of a rational choice.