|
1 | | ---- |
2 | | -name: Library change |
3 | | -about: Fix or improve issues with built-in type definitions like `lib.dom.d.ts`, `lib.es6.d.ts`, etc. |
4 | | -title: '' |
5 | | -labels: '' |
6 | | -assignees: '' |
7 | | ---- |
8 | | -# lib Update Request |
9 | | - |
10 | | -<!-- |
11 | | - Please fill in each section completely. Thank you! |
12 | | -
|
13 | | - Are you here for one of these commonly-requested lib changes? |
14 | | - * Object.keys - see https://stackoverflow.com/questions/55012174/ |
15 | | - * Array methods - see https://github.com/microsoft/TypeScript/issues/36554 |
16 | | - * parseInt, parseFloat, isFinite, isNaN, etc. - see https://github.com/microsoft/TypeScript/issues/4002 |
17 | | -
|
18 | | - The DOM lib is maintained elsewhere and you can skip a step by filing issues/PRs for the DOM at that repo. |
19 | | - See https://github.com/microsoft/TypeScript-DOM-lib-generator |
20 | | ---> |
21 | | - |
22 | | -## Configuration Check |
23 | | - |
24 | | -<!-- |
25 | | - If you're missing common new methods like Array.includes, you may have a misconfigured project. |
26 | | - Try setting `lib: "es2020"` and checking whether the type you want is present. |
27 | | - You can diagnose further by running `tsc` with `--listFilesOnly` or `--showConfig`. |
28 | | -
|
29 | | - Conversely, if you are seeing built-in methods you expect to *not* see, check your 'lib' setting |
30 | | - or review your dependencies for lib/reference directives that might be polluting |
31 | | - your global scope. This is common when using the 'node' type library. See https://github.com/microsoft/TypeScript/issues/40184 |
32 | | -
|
33 | | - Replace the text below: |
34 | | ---> |
35 | | -My compilation *target* is `ES2015` and my *lib* is `the default`. |
36 | | - |
37 | | -## Missing / Incorrect Definition |
38 | | - |
39 | | -<!-- |
40 | | - What property, method, function, etc is missing or incorrect? |
41 | | ---> |
42 | | - |
43 | | -## Sample Code |
44 | | - |
45 | | -<!-- |
46 | | - What's some code using this that should work, but doesn't? |
47 | | ---> |
48 | | - |
49 | | -## Documentation Link |
50 | | - |
51 | | -<!-- |
52 | | - Link to relevant documentation (e.g. MDN, W3C, ECMAScript Spec) to consult for this property. |
53 | | - Note that lib.dom.d.ts intentionally does not include browser-specific extensions |
54 | | - or early experimental features. |
55 | | ---> |
| 1 | +--- |
| 2 | +name: Library change |
| 3 | +about: Fix or improve issues with built-in type definitions like `lib.dom.d.ts`, `lib.es6.d.ts`, |
| 4 | + etc. |
| 5 | +title: '' |
| 6 | +labels: '' |
| 7 | +assignees: '' |
| 8 | + |
| 9 | +--- |
| 10 | + |
| 11 | +# lib Update Request |
| 12 | + |
| 13 | +<!-- |
| 14 | + Please fill in each section completely. Thank you! |
| 15 | +
|
| 16 | + Are you here for one of these commonly-requested lib changes? |
| 17 | + * Object.keys - see https://stackoverflow.com/questions/55012174/ |
| 18 | + * Array methods - see https://github.com/microsoft/TypeScript/issues/36554 |
| 19 | + * parseInt, parseFloat, isFinite, isNaN, etc. - see https://github.com/microsoft/TypeScript/issues/4002 |
| 20 | +
|
| 21 | + The DOM lib is maintained elsewhere and you can skip a step by filing issues/PRs for the DOM at that repo. |
| 22 | + See https://github.com/microsoft/TypeScript-DOM-lib-generator |
| 23 | +--> |
| 24 | + |
| 25 | +## Configuration Check |
| 26 | + |
| 27 | +<!-- |
| 28 | + If you're missing common new methods like Array.includes, you may have a misconfigured project. |
| 29 | + Try setting `lib: "es2020"` and checking whether the type you want is present. |
| 30 | + You can diagnose further by running `tsc` with `--listFilesOnly` or `--showConfig`. |
| 31 | +
|
| 32 | + Conversely, if you are seeing built-in methods you expect to *not* see, check your 'lib' setting |
| 33 | + or review your dependencies for lib/reference directives that might be polluting |
| 34 | + your global scope. This is common when using the 'node' type library. See https://github.com/microsoft/TypeScript/issues/40184 |
| 35 | +
|
| 36 | + Replace the text below: |
| 37 | +--> |
| 38 | +My compilation *target* is `ES2015` and my *lib* is `the default`. |
| 39 | + |
| 40 | +## Missing / Incorrect Definition |
| 41 | + |
| 42 | +<!-- |
| 43 | + What property, method, function, etc is missing or incorrect? |
| 44 | +--> |
| 45 | + |
| 46 | +## Sample Code |
| 47 | + |
| 48 | +<!-- |
| 49 | + What's some code using this that should work, but doesn't? |
| 50 | +--> |
| 51 | + |
| 52 | +## Documentation Link |
| 53 | + |
| 54 | +<!-- |
| 55 | + Link to relevant documentation (e.g. MDN, W3C, ECMAScript Spec) to consult for this property. |
| 56 | + Note that lib.dom.d.ts intentionally does not include browser-specific extensions |
| 57 | + or early experimental features. |
| 58 | +--> |
0 commit comments