From 611f75f16a1837914f2b25e6025acfdbbeabe9a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roberto=20Pintos=20L=C3=B3pez?= Date: Sat, 2 Nov 2024 12:34:17 +0100 Subject: [PATCH] feat(common): update ServiceIdentifier to allow Function --- .changeset/sour-eyes-sneeze.md | 5 +++++ .../common/src/services/models/ServiceIdentifier.ts | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) create mode 100644 .changeset/sour-eyes-sneeze.md diff --git a/.changeset/sour-eyes-sneeze.md b/.changeset/sour-eyes-sneeze.md new file mode 100644 index 00000000..bb4990ff --- /dev/null +++ b/.changeset/sour-eyes-sneeze.md @@ -0,0 +1,5 @@ +--- +"@inversifyjs/common": minor +--- + +Updated `ServiceIdentifier` to allow `Function` diff --git a/packages/container/libraries/common/src/services/models/ServiceIdentifier.ts b/packages/container/libraries/common/src/services/models/ServiceIdentifier.ts index 7b2835ab..f6ad1213 100644 --- a/packages/container/libraries/common/src/services/models/ServiceIdentifier.ts +++ b/packages/container/libraries/common/src/services/models/ServiceIdentifier.ts @@ -3,4 +3,6 @@ import { Newable } from './Newable'; export type ServiceIdentifier = | string | symbol - | Newable; + | Newable + // eslint-disable-next-line @typescript-eslint/no-unsafe-function-type + | Function;