From 049c51d979dc3e17af69955e58e7ee3cfd166365 Mon Sep 17 00:00:00 2001 From: Paolo Insogna Date: Wed, 24 Jan 2024 16:40:47 +0100 Subject: [PATCH] chore: Updated TypeScript configuration. --- package.json | 21 ++++++++++++--------- src/internals.ts | 2 +- tsconfig.json | 4 ++-- 3 files changed, 15 insertions(+), 12 deletions(-) diff --git a/package.json b/package.json index 053228f..90d5947 100644 --- a/package.json +++ b/package.json @@ -3,7 +3,10 @@ "version": "5.0.0", "description": "A module that finds the size and type of an image by fetching and reading as little data as needed.", "homepage": "https://sw.cowtech.it/fastimage", - "repository": "github:ShogunPanda/fastimage", + "repository": { + "type": "git", + "url": "git+https://github.com/ShogunPanda/fastimage.git" + }, "keywords": [ "fast", "fastimage", @@ -51,19 +54,19 @@ "postpublish": "git push origin && git push origin -f --tags" }, "dependencies": { - "image-size": "^1.0.2", - "undici": "^6.1.0" + "image-size": "^1.1.1", + "undici": "^6.4.0" }, "devDependencies": { - "@cowtech/eslint-config": "^9.0.0", - "@swc/cli": "^0.1.63", - "@swc/core": "^1.3.101", - "@types/node": "^20.10.5", + "@cowtech/eslint-config": "^9.0.3", + "@swc/cli": "^0.2.3", + "@swc/core": "^1.3.105", + "@types/node": "^20.11.6", "@types/tap": "^15.0.11", - "c8": "^8.0.1", + "c8": "^9.1.0", "chokidar": "^3.5.3", "concurrently": "^8.2.2", - "prettier": "^3.1.1", + "prettier": "^3.2.4", "tap": "^18.6.1", "ts-node": "^10.9.2", "typescript": "^5.3.3" diff --git a/src/internals.ts b/src/internals.ts index ca2617b..394577f 100644 --- a/src/internals.ts +++ b/src/internals.ts @@ -1,4 +1,4 @@ -import imageSize from 'image-size' +import { imageSize } from 'image-size' import type EventEmitter from 'node:events' import { createReadStream } from 'node:fs' import { type IncomingHttpHeaders } from 'node:http' diff --git a/tsconfig.json b/tsconfig.json index 6cedb6c..99b0c94 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,8 +1,8 @@ { "compilerOptions": { "target": "ES2022", - "module": "ESNext", - "moduleResolution": "node", + "module": "NodeNext", + "moduleResolution": "NodeNext", "jsx": "preserve", "declaration": true, "outDir": "dist",