From 6265afec2bf078eb71167d2f2cc51888a07f61b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tobias=20H=C3=B8egh?= Date: Tue, 14 Nov 2023 12:38:31 +0100 Subject: [PATCH] chore: remove circular dependency issue on main branch builds --- packages/dnb-eufemia/rollup.config.js | 9 +++++++++ .../extensions/forms/DataContext/Provider/Provider.tsx | 3 ++- .../src/extensions/forms/hooks/useDataValue.ts | 8 +++----- 3 files changed, 14 insertions(+), 6 deletions(-) diff --git a/packages/dnb-eufemia/rollup.config.js b/packages/dnb-eufemia/rollup.config.js index fbd9a21fa76..40b418ff611 100644 --- a/packages/dnb-eufemia/rollup.config.js +++ b/packages/dnb-eufemia/rollup.config.js @@ -49,6 +49,15 @@ export default !/^(release|beta|alpha|next|portal|main)$/.test( excludes, } ), + makeRollupConfig( + './src/umd/dnb-ui-extensions.ts', + 'build/umd/dnb-ui-extensions.min.js', + { + name: 'dnbExtensions', + format: 'umd', + excludes, + } + ), ] : [ makeRollupConfig( diff --git a/packages/dnb-eufemia/src/extensions/forms/DataContext/Provider/Provider.tsx b/packages/dnb-eufemia/src/extensions/forms/DataContext/Provider/Provider.tsx index 1fee0d5d9e4..9020d2e9dbd 100644 --- a/packages/dnb-eufemia/src/extensions/forms/DataContext/Provider/Provider.tsx +++ b/packages/dnb-eufemia/src/extensions/forms/DataContext/Provider/Provider.tsx @@ -10,7 +10,8 @@ import { JSONSchema7 } from 'json-schema' import { ValidateFunction } from 'ajv' import ajv, { ajvErrorsToFormErrors } from '../../utils/ajv' import { FormError } from '../../types' -import { useMountEffect, useUpdateEffect } from '../../hooks' +import useMountEffect from '../../hooks/useMountEffect' +import useUpdateEffect from '../../hooks/useUpdateEffect' import Context, { ContextState } from '../Context' /** diff --git a/packages/dnb-eufemia/src/extensions/forms/hooks/useDataValue.ts b/packages/dnb-eufemia/src/extensions/forms/hooks/useDataValue.ts index bdcbc1e3add..c4d52db46c1 100644 --- a/packages/dnb-eufemia/src/extensions/forms/hooks/useDataValue.ts +++ b/packages/dnb-eufemia/src/extensions/forms/hooks/useDataValue.ts @@ -15,11 +15,9 @@ import { Context } from '../DataContext' import FieldBlockContext from '../FieldBlock/FieldBlockContext' import IterateElementContext from '../Iterate/IterateElementContext' import { makeUniqueId } from '../../../shared/component-helper' -import { - useMountEffect, - useUpdateEffect, - useProcessManager, -} from '../hooks' +import useMountEffect from './useMountEffect' +import useUpdateEffect from './useUpdateEffect' +import useProcessManager from './useProcessManager' interface ReturnAdditional { id: string