Created
March 8, 2024 19:35
-
-
Save infomiho/a18421740c205d1794c36c274bf09fc8 to your computer and use it in GitHub Desktop.
Wasp with Radix UI
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
app radixui { | |
wasp: { | |
version: "^0.12.3" | |
}, | |
title: "radixui", | |
client: { | |
rootComponent: import { Layout } from "@src/Layout", | |
} | |
} | |
route RootRoute { path: "/", to: MainPage } | |
page MainPage { | |
component: import { MainPage } from "@src/MainPage" | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "radixui", | |
"dependencies": { | |
"@radix-ui/themes": "^2.0.3", | |
"react": "^18.2.0", | |
"wasp": "file:.wasp/out/sdk/wasp" | |
}, | |
"devDependencies": { | |
"@types/react": "^18.0.37", | |
"prisma": "4.16.2", | |
"typescript": "^5.1.0", | |
"vite": "^4.3.9" | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import "@radix-ui/themes/styles.css"; | |
import { Theme } from "@radix-ui/themes"; | |
export function Layout({ children }) { | |
return <Theme>{children}</Theme>; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { Flex, Text, Button } from "@radix-ui/themes"; | |
export const MainPage = () => { | |
return ( | |
<Flex direction="column" gap="2"> | |
<Text>Hello from Radix Themes :)</Text> | |
<Button>Let's go</Button> | |
</Flex> | |
); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment