generated from amazon-archives/__template_Apache-2.0
-
Notifications
You must be signed in to change notification settings - Fork 176
Closed
Labels
completedThis item is complete and has been merged/shippedThis item is complete and has been merged/shippedfeature-requestThis item refers to a feature request for an existing or new utilityThis item refers to a feature request for an existing or new utilityloggerThis item relates to the Logger UtilityThis item relates to the Logger Utility
Description
Expected Behavior
The LoggerInterface
should be able to be imported, so I can decorate the logger with my own implementation.
import { LoggerInterface } from '@aws-lambda-powertools/logger/types';
Current Behavior
The current export of logger types is missing the LoggerInterface
from Logger.d.ts
. See
powertools-lambda-typescript/packages/logger/src/types/index.ts
Lines 9 to 18 in 72803e2
export type { | |
LogItemMessage, | |
LogItemExtraInput, | |
LambdaFunctionContext, | |
UnformattedAttributes, | |
PowertoolsLogData, | |
ConstructorOptions, | |
InjectLambdaContextOptions, | |
CustomJsonReplacerFn, | |
} from './Logger.js'; |
Code snippet
import { LoggerInterface } from '@aws-lambda-powertools/logger/types';
Steps to Reproduce
- install powertools
- try to import the
LoggerInterface
- TS2305 (no exported member) error should occur
Possible Solution
Export also LoggerInterface
here
powertools-lambda-typescript/packages/logger/src/types/index.ts
Lines 9 to 18 in 72803e2
export type { | |
LogItemMessage, | |
LogItemExtraInput, | |
LambdaFunctionContext, | |
UnformattedAttributes, | |
PowertoolsLogData, | |
ConstructorOptions, | |
InjectLambdaContextOptions, | |
CustomJsonReplacerFn, | |
} from './Logger.js'; |
Powertools for AWS Lambda (TypeScript) version
latest
AWS Lambda function runtime
20.x
Packaging format used
npm
Execution logs
No response
Metadata
Metadata
Assignees
Labels
completedThis item is complete and has been merged/shippedThis item is complete and has been merged/shippedfeature-requestThis item refers to a feature request for an existing or new utilityThis item refers to a feature request for an existing or new utilityloggerThis item relates to the Logger UtilityThis item relates to the Logger Utility
Type
Projects
Status
Shipped