Open tnnevol opened 3 years ago
I get same issue , 同样的问题+1.
只能等官方修bug了吗?
不知道是不是官方小伙独爱单引号, 麻烦修改一下正则吧
// ./node_modules/vue-cli-plugin-element-plus/generator/index.js:45:45 bug fix // edit line 41 // error code const renderIndex = lines.findIndex(line => line.match(/createApp\(App\)(\.use\(\w*\))*\.mount\('#app'\)/)) // fix code const renderIndex = lines.findIndex(line => line.match(/createApp\(App\)(\.use\(\w*\))*\.mount\(['"]#app['"]\)/))
似乎还是报错
遇到同样问题
这个正则还要求匹配 createApp,如果 createApp 在另外一行就不行了
Can someone create a PR?
Does anybody know why is it not merged yet?
我也遇到相同的问题了
ERROR TypeError: Cannot read property 'replace' of undefined TypeError: Cannot read property 'replace' of undefined at D:\git\sailoudcodegit\unidownpage\node_modules\vue-cli-plugin-element-plus\generator\index.js:45:45 at runGenerator (C:\Users\censujiang\AppData\Roaming\npm\node_modules\@vue\cli\lib\invoke.js:132:13) at processTicksAndRejections (internal/process/task_queues.js:95:5) at async invoke (C:\Users\censujiang\AppData\Roaming\npm\node_modules\@vue\cli\lib\invoke.js:92:3)
不知道是不是官方小伙独爱单引号, 麻烦修改一下正则吧