Theme Object
Theme objects define the style defaults for the output, which are in turn overwritten by CSS variables. Theme objects are unwieldy monsters and less powerful than CSS variables, so you should try to use the latter if at all possible.
Default theme and theme schema
The default theme object is available as an export from the main package, together with a Zod schema to validate theme objects with. TypeScript users can also import and use the Theme
type.
import { defaultTheme, themeSchema, type Theme } from "@codemovie/code-movie";
let validatedTheme: Theme = themeSchema.parse(defaultTheme);
// Throws errors if the theme does not conform to the expected type
1234import { defaultTheme, themeSchema, type Theme } from "@codemovie/code-movie";
let validatedTheme: Theme = themeSchema.parse(defaultTheme);
// Throws errors if the theme does not conform to the expected type