refactor: Use next.js instead of vite

This commit is contained in:
bracesproul
2025-04-10 11:47:43 -07:00
parent aaee53e3e6
commit 25524792ec
18 changed files with 3761 additions and 5448 deletions

View File

@@ -128,9 +128,11 @@ export const StreamProvider: React.FC<{ children: ReactNode }> = ({
children,
}) => {
// Get environment variables
const envApiUrl: string | undefined = import.meta.env.VITE_API_URL;
const envAssistantId: string | undefined = import.meta.env.VITE_ASSISTANT_ID;
const envApiKey: string | undefined = import.meta.env.VITE_LANGSMITH_API_KEY;
const envApiUrl: string | undefined = process.env.NEXT_PUBLIC_API_URL;
const envAssistantId: string | undefined =
process.env.NEXT_PUBLIC_ASSISTANT_ID;
const envApiKey: string | undefined =
process.env.NEXT_PUBLIC_LANGSMITH_API_KEY;
// Use URL params with env var fallbacks
const [apiUrl, setApiUrl] = useQueryState("apiUrl", {