From 139bcd2937fa334b2b3e423b75dc3b378a451c72 Mon Sep 17 00:00:00 2001 From: Abourass Date: Fri, 26 Apr 2024 15:22:15 -0600 Subject: [PATCH] Update dependencies and fix TypeScript configuration --- package.json | 6 +++--- src/index.ts | 7 ++----- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/package.json b/package.json index 71d2fdf..7d7e43e 100644 --- a/package.json +++ b/package.json @@ -1,10 +1,10 @@ { "name": "@magik_io/lint_golem", "description": "A really magik lint golem", - "version": "1.3.0", + "version": "1.4.0", "engines": { - "node": "v21.7.1", - "npm": "10.5.0" + "node": "v21.*.*", + "npm": "10.*.*" }, "main": "dist/index.js", "types": "dist/index.d.ts", diff --git a/src/index.ts b/src/index.ts index 2665066..3e90029 100644 --- a/src/index.ts +++ b/src/index.ts @@ -241,15 +241,12 @@ export class LintGolem { ); } - public static async init(config: LintGolemOptions, verbose = false) { + public static async init(config: Omit & { tsconfigPaths?: Array }, verbose = false) { const tsconfigPaths = await glob([ `tsconfig.json`, `*.tsconfig.json`, ...(config.tsconfigPaths ?? []), - ], { - cwd: config.rootDir, - ignore: config.ignoreGlobs - }); + ], { cwd: config.rootDir, ignore: config.ignoreGlobs }); if (tsconfigPaths.length === 0) throw new Error('No tsconfig.json found', { cause: 'Missing projectRoot / glob failure' }); if (verbose) console.info('Found tsconfigPaths:', tsconfigPaths.join(', \n')); return new LintGolem({ ...config, tsconfigPaths });