Overlapping definition of string literals #4155
Labels
bug
This issue is a bug.
closed-for-staleness
response-requested
Waiting on additional info and feedback. Will move to \"closing-soon\" in 7 days.
Describe the bug
Generating typescript from enum shape creates overlapping string literal definitions which renders them useless. No type autocomplete, no type checking works.
aws-sdk-js/scripts/lib/ts-generator.js
Lines 342 to 345 in 49d4c27
Expected Behavior
Script generates proper string literals from enum shape:
should generate
Current Behavior
Following structure in smithy:
currently generates following definition file:
Reproduction Steps
node
)See the output:
Possible Solution
Remove
|string;
postfix if this is enum, though this is a breaking change and I'm not sure if v3 healed that.Additional Information/Context
No response
SDK version used
2.1174.0
Environment details (OS name and version, etc.)
MacOS 11.6.6, Amazon Linux 2
The text was updated successfully, but these errors were encountered: