From b3d7633617c5d59f4f51404fcb22a6c933aaed4d Mon Sep 17 00:00:00 2001 From: Cedric van Putten Date: Wed, 27 Mar 2024 16:19:05 +0100 Subject: [PATCH] fix: local webui development (#19) --- webui/src/utils/api.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/webui/src/utils/api.ts b/webui/src/utils/api.ts index e84b678..fb7a6f4 100644 --- a/webui/src/utils/api.ts +++ b/webui/src/utils/api.ts @@ -1,9 +1,10 @@ /** * Keep this path in sync with `app.json`'s `baseUrl`. + * The base url is disabled when running webui in development, as `baseUrl` is for export only. * * @see https://docs.expo.dev/versions/latest/config/app/#baseurl */ -const baseUrl = '/_expo/atlas'; +const baseUrl = __DEV__ ? '' : '/_expo/atlas'; /** * Fetch data from the API routes, adding the `baseUrl` to all requests.