redux-async-connect icon indicating copy to clipboard operation
redux-async-connect copied to clipboard

IE10 - Unable to get property 'store' of undefined or null reference

Open badtant opened this issue 8 years ago • 8 comments

Hi,

I have some problems with IE10. return this.context.store... gets Unable to get property 'store' of undefined or null reference.

_createClass(ReduxAsyncConnect, [{
        key: 'isLoaded',
        value: function isLoaded() {
          return this.context.store.getState().reduxAsyncConnect.loaded;
        }
}]);

I'm using babel 6 with the config below aswell as babel-polyfill for promises.

{
    'presets': [
        'react',
        'es2015'
    ],
    'plugins': [
        'transform-object-rest-spread',
        'transform-decorators-legacy'
    ]
}

Any idea of what might be wrong?

badtant avatar Mar 09 '16 15:03 badtant

My guess is that you need proto-to-assign in your babel config.

https://babeljs.algolia.com/docs/advanced/caveats/ https://github.com/babel/babel/tree/master/packages/babel-plugin-transform-proto-to-assign

badtant avatar Mar 11 '16 14:03 badtant

I have these problems too

hanzhao avatar Mar 15 '16 11:03 hanzhao

@magicae I made a pull request to fix this. Hope it will get merged... https://github.com/Rezonans/redux-async-connect/pull/64

badtant avatar Mar 15 '16 13:03 badtant

@sars any thoughts on this pull request?

badtant avatar Mar 16 '16 13:03 badtant

Problem solved using @badtant 's suggestion.

Astra-RX avatar Mar 22 '16 04:03 Astra-RX

I am facing the same issue, when can we expect the fix?

gerinjacob avatar May 06 '16 04:05 gerinjacob

try using https://github.com/makeomatic/redux-connect - I've refactored this module (v1 branch), as well as updated API a bit. Constraints are loosened to allow react 15.x.x as well.

npm i redux-connect -S

AVVS avatar May 06 '16 04:05 AVVS

@AVVS it's amazing, what you did?

machao23 avatar Aug 22 '16 07:08 machao23