(map, deprecatedOptionsArgument = {})
| 20 | |
| 21 | function connectFactory(defaults = {}, options = {}) { |
| 22 | function connectImpl(map, deprecatedOptionsArgument = {}) { |
| 23 | let finalOptions = options |
| 24 | if ('withRef' in deprecatedOptionsArgument) { |
| 25 | warning(false, 'The options argument is deprecated in favor of `connect.options()`. In a future release, support will be removed.') |
| 26 | finalOptions = Object.assign({}, options, { withRef: deprecatedOptionsArgument.withRef }) |
| 27 | } |
| 28 | |
| 29 | warning(!(Function.prototype.isPrototypeOf(defaults.buildRequest) && |
| 30 | Function.prototype.isPrototypeOf(defaults.Request)), |
| 31 | 'Both buildRequest and Request were provided in `connect.defaults()`. ' + |
| 32 | 'However, this custom Request would only be used in the default buildRequest.' |
| 33 | ) |
| 34 | |
| 35 | warning(options.pure === undefined, '`pure` option is no longer supported') |
| 36 | |
| 37 | return connect(map, defaults, finalOptions) |
| 38 | } |
| 39 | |
| 40 | connectImpl.defaults = function (overrides = {}) { |
| 41 | checkTypes(overrides) |
nothing calls this directly
no test coverage detected
searching dependent graphs…