From b5c5162ec0c741049a42e6806aa9bea19fdccd8e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B0=95=EB=8F=99=EC=9C=A4=20=28Donny=29?= Date: Thu, 1 Feb 2024 19:07:42 +0900 Subject: [PATCH] fix scripts --- packages/css-loader/package.json | 3 +-- packages/jest/.eslintrc | 25 +++++++++++-------------- packages/jest/index.ts | 3 +-- packages/jest/package.json | 3 +-- 4 files changed, 14 insertions(+), 20 deletions(-) diff --git a/packages/css-loader/package.json b/packages/css-loader/package.json index 2c1e1b6..b47924e 100644 --- a/packages/css-loader/package.json +++ b/packages/css-loader/package.json @@ -7,8 +7,7 @@ "license": "APACHE-2.0", "main": "lib/index.js", "scripts": { - "build": "tsc", - "test": "jest" + "build": "tsc" }, "keywords": [], "devDependencies": { diff --git a/packages/jest/.eslintrc b/packages/jest/.eslintrc index cc131cf..be49682 100644 --- a/packages/jest/.eslintrc +++ b/packages/jest/.eslintrc @@ -1,16 +1,13 @@ { - "root": true, - "parser": "@typescript-eslint/parser", - "plugins": [ - "@typescript-eslint" - ], - "extends": [ - "eslint:recommended", - "plugin:@typescript-eslint/eslint-recommended", - "plugin:@typescript-eslint/recommended" - ], - "rules": { - "quotes": ["error", "single"], - "semi": ["error", "never"] - } + "root": true, + "parser": "@typescript-eslint/parser", + "plugins": ["@typescript-eslint"], + "extends": [ + "eslint:recommended", + "plugin:@typescript-eslint/eslint-recommended", + "plugin:@typescript-eslint/recommended" + ], + "rules": { + "@typescript-eslint/no-explicit-any": "off" + } } diff --git a/packages/jest/index.ts b/packages/jest/index.ts index 838250a..d9bf340 100644 --- a/packages/jest/index.ts +++ b/packages/jest/index.ts @@ -80,9 +80,8 @@ function createTransformer( // @ts-expect-error - type overload is confused const baseCacheKey = cacheKeyFunction(src, filename, ...rest); - // @ts-expect-error - signature mismatch between Jest <27 og >=27 const options: TransformOptions = - typeof rest[0] === "string" ? rest[1] : rest[0]; + typeof rest[0] === "string" ? (rest as any)[1] : rest[0]; return crypto .createHash("sha1") diff --git a/packages/jest/package.json b/packages/jest/package.json index 7e978bb..33c892f 100644 --- a/packages/jest/package.json +++ b/packages/jest/package.json @@ -7,10 +7,9 @@ "homepage": "https://github.com/swc-project/pkgs/tree/main/packages/jest", "scripts": { "build": "tsc", - "test": "npm test --workspaces", "prepublishOnly": "npm run build && node scripts/publish_helper.js prepublish", "postpublish": "node scripts/publish_helper.js postpublish", - "lint": "eslint . --ext .ts && echo 'No lint errors found!'" + "lint": "eslint . --ext .ts" }, "keywords": [], "author": "강동윤 ",