chore: update package dependencies and adjust GraphQL upload imports
- Updated various package dependencies in package-lock.json and package.json for improved stability and performance. - Changed import paths for graphql-upload to use .mjs extensions, ensuring compatibility with ES modules. - Added @types/graphql-upload to package.json for better TypeScript support. - Adjusted Jest configuration for improved readability and maintainability.
This commit is contained in:
1702
package-lock.json
generated
1702
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
11
package.json
11
package.json
@@ -111,6 +111,7 @@
|
|||||||
"@swc/core": "^1.9.3",
|
"@swc/core": "^1.9.3",
|
||||||
"@types/bcryptjs": "^2.4.6",
|
"@types/bcryptjs": "^2.4.6",
|
||||||
"@types/express": "^4.17.17",
|
"@types/express": "^4.17.17",
|
||||||
|
"@types/graphql-upload": "^17.0.0",
|
||||||
"@types/jest": "^29.5.2",
|
"@types/jest": "^29.5.2",
|
||||||
"@types/lodash": "^4.17.13",
|
"@types/lodash": "^4.17.13",
|
||||||
"@types/luxon": "^3.4.2",
|
"@types/luxon": "^3.4.2",
|
||||||
@@ -137,13 +138,19 @@
|
|||||||
"@css-inline/css-inline-linux-x64-musl": "^0.14.3"
|
"@css-inline/css-inline-linux-x64-musl": "^0.14.3"
|
||||||
},
|
},
|
||||||
"jest": {
|
"jest": {
|
||||||
"moduleFileExtensions": ["js", "json", "ts"],
|
"moduleFileExtensions": [
|
||||||
|
"js",
|
||||||
|
"json",
|
||||||
|
"ts"
|
||||||
|
],
|
||||||
"rootDir": "src",
|
"rootDir": "src",
|
||||||
"testRegex": ".*\\.spec\\.ts$",
|
"testRegex": ".*\\.spec\\.ts$",
|
||||||
"transform": {
|
"transform": {
|
||||||
"^.+\\.(t|j)s$": "ts-jest"
|
"^.+\\.(t|j)s$": "ts-jest"
|
||||||
},
|
},
|
||||||
"collectCoverageFrom": ["**/*.(t|j)s"],
|
"collectCoverageFrom": [
|
||||||
|
"**/*.(t|j)s"
|
||||||
|
],
|
||||||
"coverageDirectory": "../coverage",
|
"coverageDirectory": "../coverage",
|
||||||
"testEnvironment": "node"
|
"testEnvironment": "node"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -5,8 +5,10 @@ import SmartSubscriptionPlugin, { subscribeOptionsFromIterator } from '@pothos/p
|
|||||||
import ZodPlugin from '@pothos/plugin-zod'
|
import ZodPlugin from '@pothos/plugin-zod'
|
||||||
import AuthzPlugin from '@pothos/plugin-authz'
|
import AuthzPlugin from '@pothos/plugin-authz'
|
||||||
import ErrorsPlugin from '@pothos/plugin-errors'
|
import ErrorsPlugin from '@pothos/plugin-errors'
|
||||||
import type { FileUpload } from 'graphql-upload/processRequest.js'
|
// @ts-expect-error
|
||||||
import GraphQLUpload from 'graphql-upload/GraphQLUpload.js'
|
import type { FileUpload } from 'graphql-upload/processRequest.mjs'
|
||||||
|
// @ts-expect-error
|
||||||
|
import GraphQLUpload from 'graphql-upload/GraphQLUpload.mjs'
|
||||||
import { Injectable, Logger } from '@nestjs/common'
|
import { Injectable, Logger } from '@nestjs/common'
|
||||||
import { PrismaCrudGenerator } from './graphql.generator'
|
import { PrismaCrudGenerator } from './graphql.generator'
|
||||||
import type PrismaTypes from '../types/pothos.generated'
|
import type PrismaTypes from '../types/pothos.generated'
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
import { Inject, Injectable, Logger } from '@nestjs/common'
|
import { Inject, Injectable, Logger } from '@nestjs/common'
|
||||||
import { ConfigService } from '@nestjs/config'
|
import { ConfigService } from '@nestjs/config'
|
||||||
import { FileUpload } from 'graphql-upload/processRequest.js'
|
// @ts-expect-error
|
||||||
|
import { FileUpload } from 'graphql-upload/processRequest.mjs'
|
||||||
import { Client, BucketItem } from 'minio'
|
import { Client, BucketItem } from 'minio'
|
||||||
import { MINIO_CONNECTION } from 'nestjs-minio'
|
import { MINIO_CONNECTION } from 'nestjs-minio'
|
||||||
import { DateTimeUtils } from 'src/common/utils/datetime.utils'
|
import { DateTimeUtils } from 'src/common/utils/datetime.utils'
|
||||||
|
|||||||
@@ -4,7 +4,8 @@ import { AppModule } from './app.module'
|
|||||||
import { Logger } from '@nestjs/common'
|
import { Logger } from '@nestjs/common'
|
||||||
import { NestFactory } from '@nestjs/core'
|
import { NestFactory } from '@nestjs/core'
|
||||||
import { clerkMiddleware } from '@clerk/express'
|
import { clerkMiddleware } from '@clerk/express'
|
||||||
import graphqlUploadExpress from 'graphql-upload/graphqlUploadExpress.js'
|
// @ts-expect-error
|
||||||
|
import graphqlUploadExpress from 'graphql-upload/graphqlUploadExpress.mjs'
|
||||||
import path from 'node:path'
|
import path from 'node:path'
|
||||||
import { readFileSync } from 'node:fs'
|
import { readFileSync } from 'node:fs'
|
||||||
import { json } from 'express'
|
import { json } from 'express'
|
||||||
|
|||||||
Reference in New Issue
Block a user