web/api: Fix Hoisted exports across entrypoints. Update Axios. (#14089)

* web/api: Fix issue where hoisted exports across entrypoints do not
order.

* web/api: Override OpenAPI transitive dep.
This commit is contained in:
Teffen Ellis
2025-04-15 20:09:41 +02:00
committed by GitHub
parent 4f4c5253dd
commit ea85331a7e
4 changed files with 522 additions and 629 deletions

View File

@ -1,4 +1,5 @@
import {
CSRFHeaderName,
CSRFMiddleware,
EventMiddleware,
LoggingMiddleware,
@ -8,6 +9,10 @@ import { globalAK } from "@goauthentik/common/global";
import { Config, Configuration, CoreApi, CurrentBrand, RootApi } from "@goauthentik/api";
// HACK: Workaround for ESBuild not being able to hoist import statement across entrypoints.
// This can be removed after ESBuild uses a single build context for all entrypoints.
export { CSRFHeaderName };
let globalConfigPromise: Promise<Config> | undefined = Promise.resolve(globalAK().config);
export function config(): Promise<Config> {
if (!globalConfigPromise) {