Warning: file_get_contents(/data/phpspider/zhask/data//catemap/6/opengl/4.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Reactjs 反应JS+;ALT(通量):了解不变冲突findComponentRoot(…,.0.1.1.0.4.2.0.1.1):无法找到元素_Reactjs_Semantic Ui_Reactjs Flux_Flux - Fatal编程技术网

Reactjs 反应JS+;ALT(通量):了解不变冲突findComponentRoot(…,.0.1.1.0.4.2.0.1.1):无法找到元素

Reactjs 反应JS+;ALT(通量):了解不变冲突findComponentRoot(…,.0.1.1.0.4.2.0.1.1):无法找到元素,reactjs,semantic-ui,reactjs-flux,flux,Reactjs,Semantic Ui,Reactjs Flux,Flux,我将REACT JS与名为ALT的通量实现一起使用 我从一个工作的React组件开始: ConfirmEditModal = React.createClass({ getInitialState(){ console.log('ConfirmEditModal - getInitialState'); var state = {sample: 'MY_SAMPLE_STATE'}; console.log(state);

我将REACT JS与名为ALT的通量实现一起使用

我从一个工作的React组件开始:

    ConfirmEditModal = React.createClass({

    getInitialState(){

        console.log('ConfirmEditModal - getInitialState');

        var state = {sample: 'MY_SAMPLE_STATE'};
        console.log(state);
        return state;
    },
    onChange(state){
        console.log('ConfirmEditModal - onChange');
        console.log(state);
        this.setState(state);
    },
    componentDidMount(){
        console.log('ConfirmEditModal - componentDidMount');
        //SeedStore.listen(this.onChange);
    },

    componentWillUnmount(){
        //SeedStore.unlisten(this.onChange);
    },


    render(){

        return (
            <div className="ui modal edit">
                <i className="close icon"></i>
                <div className="header">Form For Editing</div>
                <div className="content">

                    <div className="ui form">
                        <h4 className="ui dividing header">Birth Information</h4>

                        <div className="field">
                            <label>Name</label>
                            <input name="name" type="text" placeholder="Name"></input>
                        </div>
                    </div>
                </div>
            </div>

            );

    }
});
我得到了这个错误:

Error: Invariant Violation: findComponentRoot(..., .0.1.1.0.4.2.0.1.1): Unable to find element. This probably means the DOM was unexpectedly mutated (e.g., by the browser), usually due to forgetting a <tbody> when using tables, nesting tags like <form>, <p>, or <a>, or using non-SVG elements in an <svg> parent. Try inspecting the child nodes of the element with React ID ``.
错误:不变冲突:findComponentRoot(…,.0.1.1.0.4.2.0.1.1):无法找到元素。这可能意味着DOM发生了意外的变化(例如通过浏览器),通常是因为在使用表、嵌套标记(如,)或在父级中使用非SVG元素时忘记了。尝试检查具有React ID``的元素的子节点。
我想了解会导致此错误的幕后情况,因为据我所知……监听存储只意味着监听存储中的任何状态更改,仅此而已……它与父子组件和查找元素无关

这个错误背后的解释是什么

我想不到听一个商店会像错误所暗示的那样影响元素的发现

其他stackOverflow文章对此进行了Q/A,这表明DOM中存在非预期的更改……但侦听存储不应影响DOM,对吗???因此,我的困惑


这个错误背后的逻辑和解释是什么?

奇怪的错误。组件代码看起来不错。是什么触发了这个模态组件的挂载?嗨,对不起,我没有更新这个…这个问题与我的另一篇文章有关,我在那里找到了一个解决方案:简而言之,使用语义UI模态不是作为的子元素,也没有将模态的上下文设置为容器div…与ALT完全没有关系…我明白了。很高兴知道你找到了解决办法。
Error: Invariant Violation: findComponentRoot(..., .0.1.1.0.4.2.0.1.1): Unable to find element. This probably means the DOM was unexpectedly mutated (e.g., by the browser), usually due to forgetting a <tbody> when using tables, nesting tags like <form>, <p>, or <a>, or using non-SVG elements in an <svg> parent. Try inspecting the child nodes of the element with React ID ``.