Skip to content

Commit 767315b

Browse files
committed
fix: type error
1 parent 5ba67f0 commit 767315b

File tree

2 files changed

+7
-6
lines changed

2 files changed

+7
-6
lines changed

packages/tailwindcss-patch/src/class.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,9 @@
11
import { getClassCacheSet, getContexts, getTailwindcssEntry } from './exposeContext'
2-
import type { CacheOptions, PatchOptions, InternalCacheOptions, InternalPatchOptions } from './type'
2+
import type { CacheOptions, InternalCacheOptions, InternalPatchOptions, TailwindcssPatcherOptions } from './type'
33
import { writeCache, readCache } from './cache'
44
import { createPatch, getPatchOptions } from './patcher'
55

6-
export interface TailwindcssPatcherOptions {
7-
cache?: CacheOptions
8-
patch?: PatchOptions
9-
}
10-
export function getCacheOptions(options?: CacheOptions) {
6+
export function getCacheOptions(options?: CacheOptions | boolean) {
117
let cache: InternalCacheOptions
128
switch (typeof options) {
139
case 'undefined': {

packages/tailwindcss-patch/src/type.ts

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,8 @@ export interface InternalPatchOptions {
2020
basedir?: string
2121
custom?: (dir: string, ctx: Record<string, any>) => void
2222
}
23+
24+
export interface TailwindcssPatcherOptions {
25+
cache?: CacheOptions | boolean
26+
patch?: PatchOptions
27+
}

0 commit comments

Comments
 (0)