Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback
Extremely Popular
Go to Latest
interface TwindUserConfig
import { type TwindUserConfig } from "https://deno.land/x/fresh@1.5.1/plugins/twindv1_deps.ts";

Type Parameters

optional
Theme = BaseTheme
optional
Presets extends Preset<any>[] = Preset[]

Properties

optional
presets: Presets
optional
darkMode: DarkModeConfig

Allows to change how the dark variant is used (default: "media")

optional
darkColor: DarkColor<BaseTheme & ExtractThemes<Theme, Presets>>
optional
theme: Theme | ThemeConfig<BaseTheme & ExtractThemes<Theme, Presets>>
optional
preflight: false | MaybeArray<Preflight | PreflightThunk<BaseTheme & ExtractThemes<Theme, Presets>>>
optional
variants: Variant<BaseTheme & ExtractThemes<Theme, Presets>>[]
optional
rules: Rule<BaseTheme & ExtractThemes<Theme, Presets>>[]
optional
hash: boolean | undefined | HashFunction

Enables hashing of all classes (default: false).

If a function is given it can be used to hash only certain classes:

{
  hash(className, defaultHash) {
    if (/^[~@]\(/.test(className)) {
      // a shortcut like `~(...)` or apply like `@(...)`
      return defaultHash(className)
    }
    return className
  }
}
optional
stringify: StringifyDeclaration<BaseTheme & ExtractThemes<Theme, Presets>>
optional
ignorelist: MaybeArray<string | RegExp>
optional
finalize: MaybeArray<Finalize<Theme & BaseTheme>>