Closed Shin-Ogata closed 6 months ago
Broken by 7252a359fd11420be798b2ecb5f2d28258dd8c8b
FYI this fix has a significant overhead that can cause a 4.4x slow down (4.8s → 22s).
@alex-kinokon do you have a repro that I can use to verify a proper fix will work well? If you don't mind, please cut a ticket so we can track it and fix separately.
@timocov https://github.com/alex-kinokon/reprod: modify the version dts-bundle-generator
to 9.4.0
to see the yarn build
time to decrease from 14s to 9s.
@alex-kinokon thanks! I created #322 to investigate possible solution.
Bug report Thank you for the great job. Since v9.4.0, there is an issue where definitions referenced are lacking and then the generated file is not correct. When using v9.3.1, the equivalent of Expected output is output. (In this report, the definition of
$StringKeyPathToRecordUnion
is missing.)Input code
type $StringKeyPathToRecordUnion< TPath extends string, TValue,
export type $StringKeyPathToRecord<TPath extends string, TValue> = $UnionToIntersection< $StringKeyPathToRecordUnion<TPath, TValue>
Expected output
Actual output
Error Report N/A. Here is the output using verbose:
How to reproduce the issue
Unzip dts-bundle-generator-lack-defs.zip
npm ci
npm run bundle
dts-bundle-generator --config ./config.json --verbose
Environment