From 85bd527ff67aa30b8e6eaf789d14f85f4c5f2dab Mon Sep 17 00:00:00 2001 From: Andrew Bierman Date: Sat, 21 Dec 2024 16:34:33 -0500 Subject: [PATCH] =?UTF-8?q?=E2=9A=A1=EF=B8=8F=20switch=20to=20default=20co?= =?UTF-8?q?nfig=20to=20fix=20type=20errors=20for=20now?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/ui/src/tamagui.config.ts | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/packages/ui/src/tamagui.config.ts b/packages/ui/src/tamagui.config.ts index 435fb6eae..eccb72264 100644 --- a/packages/ui/src/tamagui.config.ts +++ b/packages/ui/src/tamagui.config.ts @@ -1,10 +1,13 @@ import { createAnimations } from '@tamagui/animations-react-native'; +import { config as defaultTamaguiConfig } from '@tamagui/config/v3'; import { createInterFont } from '@tamagui/font-inter'; import { createMedia } from '@tamagui/react-native-media-driver'; import { shorthands } from '@tamagui/shorthands'; import { themes, tokens } from '@tamagui/themes/v2'; import { createTamagui } from 'tamagui'; +// CUSTOM CONFIG + // Define fonts using createInterFont const headingFont = createInterFont({ size: { @@ -72,7 +75,7 @@ const animations = createAnimations({ }); // Create Tamagui config -export const config = createTamagui({ +export const customConfig = createTamagui({ defaultTheme: 'dark', defaultFont: 'body', shouldAddPrefersColorThemes: true, @@ -109,5 +112,13 @@ export const config = createTamagui({ animations, }); +// DEFAULT CONFIG +export const defaultConfig = createTamagui(defaultTamaguiConfig); + +// Handle export for either config +const effectiveConfig = defaultConfig; + +export const config = effectiveConfig; + // for the compiler to find it export default config;