create-sonamu 0.1.4 → 0.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-sonamu",
3
- "version": "0.1.4",
3
+ "version": "0.1.5",
4
4
  "description": "Create a new Sonamu project",
5
5
  "keywords": [
6
6
  "sonamu",
@@ -39,7 +39,7 @@
39
39
  "knex": "^3.1.0",
40
40
  "pg": "^8.16.3",
41
41
  "radashi": "^12.2.0",
42
- "sonamu": "^0.7.51",
42
+ "sonamu": "^0.7.53",
43
43
  "zod": "^4.3.6"
44
44
  },
45
45
  "devDependencies": {
@@ -49,8 +49,8 @@ export default defineConfig({
49
49
  // nothing yet
50
50
  },
51
51
  },
52
-
53
- auth:{
52
+
53
+ auth: {
54
54
  emailAndPassword: { enabled: true },
55
55
  baseURL: process.env.BETTER_AUTH_URL ?? `http://${host}:${port}`,
56
56
  secret: process.env.BETTER_AUTH_SECRET ?? "miomock-secret-key-change-this-in-production",
@@ -25,7 +25,8 @@
25
25
  "react-day-picker": "catalog:",
26
26
  "react-dom": "catalog:",
27
27
  "tailwind-merge": "catalog:",
28
- "zod": "catalog:"
28
+ "zod": "catalog:",
29
+ "better-auth": "catalog:"
29
30
  },
30
31
  "devDependencies": {
31
32
  "@iconify-json/lucide": "catalog:",
@@ -3,7 +3,7 @@ import { useRouterState } from "@tanstack/react-router";
3
3
  import { TanStackRouterDevtools } from "@tanstack/react-router-devtools";
4
4
  import { type ReactNode, Suspense, useEffect } from "react";
5
5
  import Sidebar from "./components/Sidebar";
6
- import { setLocale } from "./i18n/sd.generated";
6
+ import { SUPPORTED_LOCALES, setLocale } from "./i18n/sd.generated";
7
7
 
8
8
  interface AppProps {
9
9
  children?: ReactNode;
@@ -17,8 +17,8 @@ function App({ children }: AppProps) {
17
17
  useEffect(() => {
18
18
  // 브라우저 locale 감지
19
19
  const browserLocale = navigator.language.split("-")[0];
20
- if (["ko", "en"].includes(browserLocale)) {
21
- setLocale(browserLocale as "ko" | "en");
20
+ if (SUPPORTED_LOCALES.includes(browserLocale as typeof SUPPORTED_LOCALES[number])) {
21
+ setLocale(browserLocale as typeof SUPPORTED_LOCALES[number]);
22
22
  }
23
23
  }, []);
24
24
 
@@ -0,0 +1,3 @@
1
+ import { createAuthClient } from "better-auth/react";
2
+
3
+ export const { signIn, signUp, useSession, signOut } = createAuthClient();