eslint prettier 规范配置 问题解决集

137 阅读1分钟

eslint 配置文件 .eslintrc.js

❓ Parsing error: '>' expected.

module.exports = {
    parser: 'vue-eslint-parser',   //添加 vue 解析器
};

❓ The template root requires an element rather than texts.

❓ The template root requires exactly one element.

module.exports = {
    rules: {
        'vue/no-multiple-template-root': 0,
    },
};