Files
vue-ts-example/src/types/unocss.ts
严浩 695e583136
All checks were successful
/ build-and-deploy-to-vercel (push) Successful in 3m7s
/ lint-build-and-check (push) Successful in 5m27s
/ playwright (push) Successful in 1m40s
/ surge (push) Successful in 3m10s
/ cleanup_surge (push) Successful in 49s
feat: 添加对 .md 文件的类型声明
2025-05-02 23:10:38 +08:00

21 lines
711 B
TypeScript

// https://unocss.dev/presets/attributify#vue-3
// https://github.com/unocss/unocss/pull/4095
// type BasicAttributesFix = import('@unocss/preset-attributify').BasicAttributes | 'b';
// type AttributifyNames<Prefix extends string = ''> =
// | `${Prefix}${BasicAttributesFix}`
// | `${Prefix}${PseudoPrefix}:${BasicAttributes}`;
// declare module '@vue/runtime-dom' {
// interface HTMLAttributes extends Partial<Record<AttributifyNames, string | boolean>> {}
// }
declare module 'vue' {
// eslint-disable-next-line @typescript-eslint/no-empty-object-type
interface HTMLAttributes
extends Partial<Record<import('@unocss/preset-attributify').AttributifyNames, boolean | string>> {}
}
export {};