在Vue中使用x-data-spreadsheet
在Vue中使用x-data-spreadsheet 1.引入x-data-spreadsheet 包 cnpm i --save x-data-spreadsheet 需要引入依赖包 cnpm i --save less-loader 构建对应vue文件 <template> <div id="x-spreadsheet-demo"></div> </template> <script> import Spreadsheet from 'x-data-spreadsheet'; import zhCN from 'x-data-spreadsheet/dist/locale/zh-cn'; Spreadsheet.locale('zh-cn', zhCN); export default { name: "xspreadsheet-demo", data() { return { jsondata: { type: '', label: '' }, }; }, mounted() { this.init() }, methods:{ init(){ const rows10 = { len: 100000 }; for (let i = 0; i < 100000; i += 1) { rows10[i] = { cells: { 0: { text: 'A-' + i }, 1: