Skip to content

Documentation Improvement: inconsistency Tracer.ts example code - Tracer Website Docs #1142

Closed
@niko-achilles

Description

@niko-achilles

Expected Behaviour

consistency of generated Docs for Tracer -> Lambda Handler -> Manual
Links:

with

Tracer.ts code example snippet in IDE editor
Link: https://github.com/awslabs/aws-lambda-powertools-typescript/blob/main/packages/tracer/src/Tracer.ts#L80

Current Behaviour

Using my IDE and reading the documentation on how to use the Tracer i read
that i should additionally import { Segment } from 'aws-xray-sdk-core';
See line: https://github.com/awslabs/aws-lambda-powertools-typescript/blob/main/packages/tracer/src/Tracer.ts#L80

This is inconsistent with the docs generated on the Website:
See Tracer -> Lambda Handler -> Manual

Links:

Code snippet

see expected and current behavior description

Possible Solution

see expected behavior

Steps to Reproduce

import Tracer in IDE and follow the example without switching to online Docs of Powertools.

AWS Lambda Powertools for TypeScript version

latest

AWS Lambda function runtime

16.x

Packaging format used

Lambda Layers

Debugging logs

No response

Metadata

Metadata

Assignees

Labels

completedThis item is complete and has been merged/shippeddocumentationImprovements or additions to documentationnot-a-bugNew and existing bug reports incorrectly submitted as bugtracerThis item relates to the Tracer Utility

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions