var text = this.state.products.join('\n');console.log(text)var input = document.getElementById("selcctDom");input.value = text; // 修改文本框的内容input.select(); // 选中文本document.execCommand("copy"); // 执行浏览器复制命令
博客园 © 2004-2025 浙公网安备 33010602011771号 浙ICP备2021040463号-3