在Internet Explorer 11中对于React 15.4.1,对象不被视为有效的React子组件。

16 浏览
0 Comments

在Internet Explorer 11中对于React 15.4.1,对象不被视为有效的React子组件。

对象不可作为React子元素(找到的是具有键{$$typeof,type,key,ref,props,_owner,_store}的对象)。如果您想要渲染一组子元素,请改用数组或使用React附加组件中的createFragment(object)包装该对象。请检查App的渲染方法。

AppContainer:

const mapDispatchToProps = (dispatch) => {
    return {
    }
}
}

组件:

class App extends Component {
    render() {
        return (
        );
    }
}

上面是我在app.js中的渲染函数。这段代码在谷歌浏览器中运行良好,但在Internet Explorer中不起作用,会抛出上述错误。

0