From 59f18572f49182ac059b45bda14f42dca69ee3af Mon Sep 17 00:00:00 2001 From: Hongbo Wu Date: Fri, 8 Mar 2024 18:19:51 +0800 Subject: [PATCH] update dependencies --- .github/workflows/ci.yml | 2 +- README.md | 2 +- package.json | 22 +++++++++++----------- src/client.ts | 2 +- src/errors.ts | 2 +- tsconfig.json | 7 +++---- 6 files changed, 18 insertions(+), 19 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 541ab06..6f5efe3 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -15,7 +15,7 @@ jobs: strategy: matrix: - node-version: [16.x, 18.x, 20.x] + node-version: [18.x, 20.x] steps: - uses: actions/checkout@v2 diff --git a/README.md b/README.md index e1cffc6..17d675c 100644 --- a/README.md +++ b/README.md @@ -181,7 +181,7 @@ The `Omnivore` class accepts an options object with the following properties: ## Requirements -- Node.js 16 or later +- Node.js 18 or later ## License diff --git a/package.json b/package.json index a87fb4e..b2ed876 100644 --- a/package.json +++ b/package.json @@ -1,11 +1,11 @@ { "name": "@omnivore-app/api", - "version": "1.0.0", + "version": "1.0.1", "description": "Omnivore API Client Library for Node.js", "main": "./dist/src/index.js", "types": "./dist/src/index.d.ts", "engines": { - "node": ">=16.0.0" + "node": ">=18.0.0" }, "files": [ "dist/src" @@ -18,8 +18,8 @@ ], "scripts": { "build": "tsc", - "lint": "eslint . --ext .ts", - "lint:fix": "eslint . --ext .ts --fix" + "lint": "eslint .", + "lint:fix": "eslint . --fix" }, "repository": { "type": "git", @@ -32,21 +32,21 @@ }, "homepage": "https://github.com/omnivore-app/omnivore-api#readme", "dependencies": { - "gql.tada": "^1.3.1", - "urql": "^4.0.6" + "@urql/core": "^4.3.0", + "gql.tada": "^1.3.1" }, "devDependencies": { - "@0no-co/graphqlsp": "^1.4.2", - "@typescript-eslint/eslint-plugin": "^7.1.0", - "@typescript-eslint/parser": "^7.1.0", + "@0no-co/graphqlsp": "^1.4.3", + "@typescript-eslint/eslint-plugin": "^7.1.1", + "@typescript-eslint/parser": "^7.1.1", "eslint": "^8.57.0", "eslint-config-prettier": "^9.1.0", "eslint-plugin-prettier": "^5.1.3", "prettier": "^3.2.5", - "typescript": "^5.3.3" + "typescript": "5.3.3" }, "volta": { - "node": "18.16.1", + "node": "18.18.0", "yarn": "1.22.19" } } diff --git a/src/client.ts b/src/client.ts index 1348f52..c868cb3 100644 --- a/src/client.ts +++ b/src/client.ts @@ -1,4 +1,4 @@ -import { Client, fetchExchange } from 'urql' +import { Client, fetchExchange } from '@urql/core' import { buildOmnivoreError } from './errors' import { DeleteMutation, diff --git a/src/errors.ts b/src/errors.ts index af2242e..547a17f 100644 --- a/src/errors.ts +++ b/src/errors.ts @@ -1,4 +1,4 @@ -import { CombinedError } from 'urql' +import { CombinedError } from '@urql/core' // Error codes are used to identify the type of error that occurred export enum OmnivoreErrorCode { diff --git a/tsconfig.json b/tsconfig.json index 8592824..bafffde 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,7 +1,7 @@ { "compilerOptions": { - "module": "commonjs", - "target": "es2020", + "module": "CommonJS", + "target": "es2022", "rootDir": ".", "outDir": "dist", "esModuleInterop": true, @@ -17,6 +17,5 @@ } ] }, - "include": ["src/**/*.ts"], - "exclude": ["node_modules"] + "include": ["src/**/*.ts"] }