mirror of
https://github.com/whoisclebs/lodash.git
synced 2026-02-02 16:17:50 +00:00
Add note about _.runInContext to _.mixin docs. [ci skip]
This commit is contained in:
@@ -11065,6 +11065,9 @@
|
||||
* destination object. If `object` is a function then methods are added to
|
||||
* its prototype as well.
|
||||
*
|
||||
* **Note:** Use `_.runInContext` to create a pristine `lodash` function
|
||||
* for mixins to avoid conflicts caused by modifying the original.
|
||||
*
|
||||
* @static
|
||||
* @memberOf _
|
||||
* @category Utility
|
||||
@@ -11082,7 +11085,7 @@
|
||||
* });
|
||||
* }
|
||||
*
|
||||
* // use `_.runInContext` to avoid potential conflicts (esp. in Node.js)
|
||||
* // use `_.runInContext` to avoid conflicts (esp. in Node.js)
|
||||
* var _ = require('lodash').runInContext();
|
||||
*
|
||||
* _.mixin({ 'vowels': vowels });
|
||||
|
||||
Reference in New Issue
Block a user