Have separate SITE_URL env from API_URL (#234)

This commit is contained in:
Frank Noirot
2023-08-07 13:07:40 -04:00
committed by GitHub
parent 62dc07e117
commit 6e14dbaf77
4 changed files with 5 additions and 2 deletions

View File

@ -4,7 +4,7 @@ import { isTauri } from '../lib/isTauri'
import { useStore } from '../useStore'
import { invoke } from '@tauri-apps/api/tauri'
import { useNavigate } from 'react-router-dom'
import { VITE_KC_API_BASE_URL } from '../env'
import { VITE_KC_SITE_BASE_URL } from '../env'
const SignIn = () => {
const navigate = useNavigate()
@ -69,7 +69,7 @@ const SignIn = () => {
) : (
<ActionButton
Element="link"
to={`${VITE_KC_API_BASE_URL}/signin?callbackUrl=${encodeURIComponent(
to={`${VITE_KC_SITE_BASE_URL}/signin?callbackUrl=${encodeURIComponent(
typeof window !== 'undefined' &&
window.location.href.replace('signin', '')
)}`}