chore: fix lint/ts errors

This commit is contained in:
pooya parsa 2020-10-29 18:32:53 +01:00
parent c0e565cbe7
commit 08e0f71946
2 changed files with 4 additions and 3 deletions

View File

@ -78,7 +78,7 @@ export type ModuleHandler<T = any> = (this: ModuleThis, moduleOptions: T) => Pro
export type NuxtModule = string | ModuleHandler | [string | ModuleHandler, any]
export type ServerMiddleware = string | { path: string, prefix?: boolean, handler: string | NextHandleFunction } | NextHandleFunction
export type ServerMiddleware = string | { path: string, prefix?: boolean, handler: string | express.NextFunction } | express.NextFunction
interface CommonConfiguration {
_modules: NuxtModule[]
@ -113,7 +113,7 @@ interface CommonConfiguration {
modules: NuxtModule[]
privateRuntimeConfig: Record<string, any> | ((env: NodeJS.ProcessEnv) => Record<string, any>)
publicRuntimeConfig: Record<string, any> | ((env: NodeJS.ProcessEnv) => Record<string, any>)
serverMiddleware: Array<ServerMiddleware> | Record<string, expr>
serverMiddleware: Array<ServerMiddleware> | Record<string, express.Handler>
ssr: boolean
target: Target
test: boolean

View File

@ -2,6 +2,7 @@
import type { ServerResponse, IncomingMessage } from 'http'
import type { CompressionOptions } from 'compression'
import type { ServeStaticOptions } from 'serve-static'
import type etag from 'etag'
import type { ServerMiddleware } from './_common'
interface PreloadFile {
@ -40,7 +41,7 @@ interface RenderOptions {
unsafeInlineCompatibility?: boolean
}
dist: ServeStaticOptions
etag: false | EtagOptions & {
etag: false | etag.Options & {
hash?: (html: string) => string
}
fallback?: {