javascript - Using Lo-Dash and Underscore simulatenously in RequireJS environment -
in requirejs environment, what's best way allow amd modules use lo-dash while others simultaneously use underscore?
i able solve problem myself simply. use lodash
path modules require lo-dash , underscore
modules require "underscore":
require.config({ paths: { 'underscore': 'path-to-my-underscore-file', 'lodash': 'path-to-my-lodash-file' } });
in way, 2 libraries can used simultaneously without interference.
contrary popular belief , claims, lo-dash not perfect drop-in replacement underscore.
Comments
Post a Comment