react map循环的dom,点击让当前数组里的isShow显示false

    changeTitle = (data, index) => {
        const { bottomOrgList } = this.state
        const newList = bottomOrgList.map((v, i) => {
            const newV = {
                ...v,
                isShow: i === index ? false : true
            }
            return newV
        })
       
        
        this.setState({
            flagValue: data.orgName,
            editTitle: data.orgName,
            bottomOrgList: newList
        })
        
       
    }
原文地址:https://www.cnblogs.com/whlBooK/p/12067776.html