diff --git a/packages/backend-core/src/index.ts b/packages/backend-core/src/index.ts index 74e79e7b95..d9dbe58264 100644 --- a/packages/backend-core/src/index.ts +++ b/packages/backend-core/src/index.ts @@ -18,6 +18,7 @@ import * as dbConstants from "./db/constants" import logging from "./logging" import pino from "./pino" import * as middleware from "./middleware" +import plugins from "./plugin" // mimic the outer package exports import * as db from "./pkg/db" @@ -56,6 +57,7 @@ const core = { errors, logging, roles, + plugins, ...pino, ...errorClasses, middleware, diff --git a/packages/backend-core/src/plugin/index.ts b/packages/backend-core/src/plugin/index.ts index 3eeaeaa90c..a6d1853007 100644 --- a/packages/backend-core/src/plugin/index.ts +++ b/packages/backend-core/src/plugin/index.ts @@ -1 +1,7 @@ -export * from "./utils" +import * as utils from "./utils" + +const pkg = { + ...utils, +} + +export = pkg diff --git a/packages/server/src/module.d.ts b/packages/server/src/module.d.ts index eb1d1feb48..ada45a3a66 100644 --- a/packages/server/src/module.d.ts +++ b/packages/server/src/module.d.ts @@ -11,3 +11,4 @@ declare module "@budibase/backend-core/encryption" declare module "@budibase/backend-core/utils" declare module "@budibase/backend-core/redis" declare module "@budibase/backend-core/objectStore" +declare module "@budibase/backend-core/plugins"