Skip to content

Commit

Permalink
add VITE_ prefix to secrets to match vercel requirements
Browse files Browse the repository at this point in the history
  • Loading branch information
armandobelardo committed Jun 21, 2024
1 parent fa90eb4 commit d339762
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/ui/fern-dashboard/src/utils.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
export function getEnvVar(name: string, fallback?: string) {
if (!name.startsWith("VITE_")) {
name = "VITE_" + name;
}
return import.meta.env[name] ?? process?.env?.[name] ?? fallback ?? name;
}

0 comments on commit d339762

Please sign in to comment.