Unhandled Rejection (TypeError): JSON.stringify is not a function

拼写错误

@action async update_tree(tree = null) {
        if (!tree) tree = this.current_tree;
        let params = {};
        console.log(tree.children);
        params["tree"] = JSON.stringify(tree.children);
        const { data } = await api.post(APIBASE + 'nodes/update', params);
        if (data) this.current_tree = data;
}

你可能感兴趣的:(#,React)