andrewhathaway / Winterfell

Generate complex, validated and extendable JSON-based forms in React.
http://winterfell.andrewhathaway.net
MIT License
785 stars 116 forks source link

Avoid conflicts with underscore #40

Closed algm closed 9 years ago

algm commented 9 years ago

In our environment we are using underscore. We found that the Winterfell version of lodash was overriding the global _ variable causing all kind of (not so) fun bugs. To avoid that I added the .noConflict() method call to all places where lodash is included.

We tried using modular lodash, which we failed because Winterfell uses chaining. We also tried including it as an external dependency making it agnostic of both _ libraries which also failed because Winterfell uses methods that are not compatible with underscore.

andrewhathaway commented 9 years ago

Ahh. Good addition. Merging.

I'll also be taking a look at your other PRs, and the issues against Winterfell this weekend. Thanks!