mirror of
https://github.com/LukeHagar/better-auth.git
synced 2025-12-07 12:27:44 +00:00
docs: v1.2 release notes (#1602)
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
import { clsx, type ClassValue } from "clsx";
|
||||
import { twMerge } from "tailwind-merge";
|
||||
|
||||
export function cn(...inputs: ClassValue[]) {
|
||||
return twMerge(clsx(inputs));
|
||||
}
|
||||
@@ -12,3 +11,14 @@ export function kFormatter(num: number) {
|
||||
? Math.sign(num) * parseFloat((Math.abs(num) / 1000).toFixed(1)) + "k"
|
||||
: Math.sign(num) * Math.abs(num);
|
||||
}
|
||||
|
||||
export const baseUrl =
|
||||
process.env.NODE_ENV === "development" || !process.env.VERCEL_URL
|
||||
? new URL("http://localhost:3000")
|
||||
: new URL(`https://${process.env.VERCEL_URL}`);
|
||||
export function formatDate(date: Date) {
|
||||
let d = new Date(date);
|
||||
return d
|
||||
.toLocaleDateString("en-US", { month: "short", day: "numeric" })
|
||||
.replace(",", "");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user