Skip to content

Commit c05f3ed

Browse files
authored
Merge pull request reduxjs#474 from jimbolla/unhide-new-features
exposes new features to the API
2 parents 6390ec7 + c67e59c commit c05f3ed

File tree

3 files changed

+3
-12
lines changed

3 files changed

+3
-12
lines changed

src/connect/connect.js

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -39,18 +39,9 @@ export function buildConnectOptions(
3939
mergePropsFactories = defaultMergePropsFactories,
4040
selectorFactory = defaultSelectorFactory,
4141
pure = true,
42-
__ENABLE_SECRET_EXPERIMENTAL_FEATURES_DO_NOT_USE_OR_YOU_WILL_BE_FIRED = false,
4342
...options
4443
} = {}
4544
) {
46-
if (!__ENABLE_SECRET_EXPERIMENTAL_FEATURES_DO_NOT_USE_OR_YOU_WILL_BE_FIRED) {
47-
mapStateToPropsFactories = defaultMapStateToPropsFactories
48-
mapDispatchToPropsFactories = defaultMapDispatchToPropsFactories
49-
mergePropsFactories = defaultMergePropsFactories
50-
selectorFactory = defaultSelectorFactory
51-
options = { withRef: options.withRef }
52-
}
53-
5445
const initMapStateToProps = match(mapStateToProps, mapStateToPropsFactories)
5546
const initMapDispatchToProps = match(mapDispatchToProps, mapDispatchToPropsFactories)
5647
const initMergeProps = match(mergeProps, mergePropsFactories)

src/index.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import Provider from './components/Provider'
2+
import connectAdvanced from './components/connectAdvanced'
23
import connect from './connect/connect'
34

4-
export { Provider, connect }
5+
export { Provider, connectAdvanced, connect }

test/components/connect.spec.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2001,8 +2001,7 @@ describe('React', () => {
20012001
})
20022002

20032003
it('should allow custom displayName', () => {
2004-
// TODO remove __ENABLE_SECRET_EXPERIMENTAL_FEATURES_DO_NOT_USE_OR_YOU_WILL_BE_FIRED once approved
2005-
@connect(null, null, null, { getDisplayName: name => `Custom(${name})`, __ENABLE_SECRET_EXPERIMENTAL_FEATURES_DO_NOT_USE_OR_YOU_WILL_BE_FIRED: true })
2004+
@connect(null, null, null, { getDisplayName: name => `Custom(${name})` })
20062005
class MyComponent extends React.Component {
20072006
render() {
20082007
return <div></div>

0 commit comments

Comments
 (0)