From c20aabdfd073e41f074adf53f1eff1d01fbf3afe Mon Sep 17 00:00:00 2001 From: Kane Wang Date: Mon, 20 Mar 2023 18:05:44 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=9D=E5=AD=98=E8=BF=9B=E5=BA=A6=EF=BC=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- code/web/task_schedule/.eslintrc.cjs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/code/web/task_schedule/.eslintrc.cjs b/code/web/task_schedule/.eslintrc.cjs index 8dc9950..200a7c4 100644 --- a/code/web/task_schedule/.eslintrc.cjs +++ b/code/web/task_schedule/.eslintrc.cjs @@ -7,7 +7,6 @@ * * Copyright (c) ${2022} by Kane, All Rights Reserved. */ - module.exports = { root: true, env: { // 需要在env中指定运行的环境,这些环境其实就是一组预定义的全局变量,让 ESLint 知道当前环境存在这些全局变量 @@ -16,10 +15,13 @@ module.exports = { es2021: true, }, parser:"espree", + parserOptions:{ + sourceType: "module", + ecmaVersion: 2021, + }, extends:["eslint:recommended",], rules:{ indent: ["warn", 4,], - // "space-in-parens": ["error", "always", { exceptions: ["empty",], },], "no-console": process.env.NODE_ENV === "production" ? "warn" : "off", "no-debugger": process.env.NODE_ENV === "production" ? "warn" : "off", "no-unused-vars": "warn",