1. Parsing error: Adjacent JSX elements must be wrapped in an enclosing tag
解決方案:修改.eslintrc.js
1 // 初始 2 3 "parser": "babel-eslint", 4 5 // 改為 6 "parserOptions": { 7 "parser": "babel-eslint" 8 },
2. Parsing error: sourceType 'module' is not supported when ecmaVersion < 2015. Consider adding `{ ecmaVersion: 2015 }` to the parser options
解決方案:修改.eslintrc.js【當ecmaVersion <2015時,不支持sourceType'module'】
parserOptions: { "ecmaVersion": 2015 },