* Creates a clone of the chain sequence planting `value` as the wrapped value. * * @name plant * @memberOf _ * @since 3.2.0 * @category Seq * @param {*} value The value to plant. * @returns {Object} Returns the new `lodash` wrapper instance. * @example *
(value)
| 9070 | * // => [1, 4] |
| 9071 | */ |
| 9072 | function wrapperPlant(value) { |
| 9073 | var result, |
| 9074 | parent = this; |
| 9075 | |
| 9076 | while (parent instanceof baseLodash) { |
| 9077 | var clone = wrapperClone(parent); |
| 9078 | clone.__index__ = 0; |
| 9079 | clone.__values__ = undefined; |
| 9080 | if (result) { |
| 9081 | previous.__wrapped__ = clone; |
| 9082 | } else { |
| 9083 | result = clone; |
| 9084 | } |
| 9085 | var previous = clone; |
| 9086 | parent = parent.__wrapped__; |
| 9087 | } |
| 9088 | previous.__wrapped__ = value; |
| 9089 | return result; |
| 9090 | } |
| 9091 | |
| 9092 | /** |
| 9093 | * This method is the wrapper version of `_.reverse`. |
nothing calls this directly
no test coverage detected