chore: lint (#7213)

This commit is contained in:
HomWang 2022-09-04 16:31:08 +08:00 committed by Pooya Parsa
parent 6c93269e73
commit 1fc34e6c06
3 changed files with 3 additions and 3 deletions

View File

@ -6,7 +6,7 @@ export default defineNuxtPlugin((nuxtApp) => {
if (logs.length > 0) {
const ssrLogStyle = 'background: #003C3C;border-radius: 0.5em;color: white;font-weight: bold;padding: 2px 0.5em;'
console.groupCollapsed && console.groupCollapsed('%cNuxt Server Logs', ssrLogStyle)
logs.forEach((logObj:any) => (console[logObj.type as 'log'] || console.log)(...logObj.args))
logs.forEach((logObj: any) => (console[logObj.type as 'log'] || console.log)(...logObj.args))
delete nuxtApp.payload.logs
console.groupEnd && console.groupEnd()
}

View File

@ -19,5 +19,5 @@ export function createIsExternal (viteServer: ViteDevServer, rootDir: string) {
}
}
return (id:string) => isExternal(id, rootDir, externalOpts)
return (id: string) => isExternal(id, rootDir, externalOpts)
}

View File

@ -30,7 +30,7 @@ export default class VueSSRServerPlugin {
return cb()
}
const entryAssets = entryInfo.assets!.filter((asset: { name:string }) => isJS(asset.name))
const entryAssets = entryInfo.assets!.filter((asset: { name: string }) => isJS(asset.name))
if (entryAssets.length > 1) {
throw new Error(