我有一个对象,我想直接在当前作用域内引用该对象。但是我不能。欢迎任何建议。
const defaultState={
targetFilters:[...],//a very complicated one
tempFilters:this.targetFilters,// this is a copy of targetFilters, and it functions as a temp copy, so I want to refer to it directly. But if I use "this.", the tempFilters becomes undefined
};