chore: fix strict lint

This commit is contained in:
YunYouJun 2023-07-10 22:20:55 +08:00
parent a45d6f1433
commit 2698f01064
7 changed files with 7 additions and 7 deletions

View File

@ -440,7 +440,7 @@ export interface ValaxyExtendConfig {
markdown?: MarkdownOptions
extendMd?: (ctx: {
route: {
meta: { frontmatter: Record<string, any>; layout?: string } & {}
meta: { frontmatter: Record<string, any>; layout?: string } & object
path: string
component: string
}

View File

@ -220,7 +220,7 @@ export function createFireworks(config: Partial<FireworksConfig>) {
}
const render = anime({
duration: Infinity,
duration: Number.POSITIVE_INFINITY,
update: () => {
ctx.clearRect(0, 0, canvasEl.width, canvasEl.height)
},

View File

@ -54,7 +54,7 @@ export async function generateFuseList(options: ResolvedValaxyOptions) {
* valaxy fuse
* @param cli
*/
export function registerFuseCommand(cli: Argv<{}>) {
export function registerFuseCommand(cli: Argv<object>) {
cli.command(
'fuse [root]',
'generate fuse list for search',

View File

@ -5,7 +5,7 @@ import { type CreatePostParams, create } from './utils/post'
* register new post command
* @param cli
*/
export function registerNewCommand(cli: Argv<{}>) {
export function registerNewCommand(cli: Argv<object>) {
cli.command(
'new <title>',
'Draft a new post',

View File

@ -5,7 +5,7 @@ import type { Argv } from 'yargs'
* @param args
* @returns
*/
export function commonOptions(args: Argv<{}>) {
export function commonOptions(args: Argv<object>) {
return args.positional('root', {
default: '.',
type: 'string',

View File

@ -2,7 +2,7 @@ import type { DefaultThemeConfig, ValaxyAddon } from '../../types'
import type { ResolvedValaxyOptions } from '../options'
import type { ValaxyNodeConfig } from '../types'
export function defineValaxyAddon<AddonOptions = {}>(
export function defineValaxyAddon<AddonOptions = object>(
addonFunc: (addonOptions?: AddonOptions, valaxyOptions?: ResolvedValaxyOptions) => ValaxyAddon,
) {
return addonFunc

View File

@ -47,7 +47,7 @@ export interface ValaxyExtendConfig {
markdown?: MarkdownOptions
extendMd?: (ctx: {
route: {
meta: { frontmatter: Record<string, any>; layout?: string } & {}
meta: { frontmatter: Record<string, any>; layout?: string } & object
path: string
component: string
}