Skip to content

Commit 949bcb3

Browse files
authored
fix types nesting (#7914)
`Partial` is only 1 level deep. We don't want it to be recursively deep, that's for the plugin itself to decide. But the parts under `theme` should all be optional.
1 parent c6b3f96 commit 949bcb3

File tree

1 file changed

+12
-11
lines changed

1 file changed

+12
-11
lines changed

types/config.d.ts

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -304,19 +304,20 @@ interface RequiredConfig {
304304
}
305305

306306
interface OptionalConfig {
307-
important: ImportantConfig
308-
prefix: PrefixConfig
309-
separator: SeparatorConfig
310-
safelist: SafelistConfig
311-
presets: PresetsConfig
312-
future: FutureConfig
313-
experimental: ExperimentalConfig
314-
darkMode: DarkModeConfig
315-
theme: ThemeConfig
316-
corePlugins: CorePluginsConfig
317-
plugins: PluginsConfig
307+
important: Partial<ImportantConfig>
308+
prefix: Partial<PrefixConfig>
309+
separator: Partial<SeparatorConfig>
310+
safelist: Partial<SafelistConfig>
311+
presets: Partial<PresetsConfig>
312+
future: Partial<FutureConfig>
313+
experimental: Partial<ExperimentalConfig>
314+
darkMode: Partial<DarkModeConfig>
315+
theme: Partial<ThemeConfig>
316+
corePlugins: Partial<CorePluginsConfig>
317+
plugins: Partial<PluginsConfig>
318318
/** Custom */
319319
[key: string]: any
320320
}
321321

322322
export type Config = RequiredConfig & Partial<OptionalConfig>
323+

0 commit comments

Comments
 (0)