Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ npx tsc --noEmit

With this configuration, TypeScript accepts supported JavaScript APIs that are Baseline Widely available. TypeScript reports APIs outside this target as errors.

Examples include `Promise.withResolvers` and `Array.fromAsync` before they reach this Baseline status. The project goal is first-class `--lib baseline` support in TypeScript.
Examples include `Promise.try` and `Intl.Segmenter` before they reach this Baseline status. The project goal is first-class `--lib baseline` support in TypeScript.

For more configurations, read the [Usage Guide](docs/USAGE.md).

Expand All @@ -46,10 +46,10 @@ The generator does not add unavailable runtime APIs to support third-party packa

## Allow a polyfilled feature

If the runtime loads an audited polyfill, add its generated `web-features` entry after the base package. For example, core-js can provide `Promise.withResolvers`:
If the runtime loads an audited polyfill, add its generated `web-features` entry after the base package. For example, core-js can provide `Promise.try`:

```ts
import "core-js/proposals/promise-with-resolvers";
import "core-js/proposals/promise-try";
```

```json
Expand All @@ -58,7 +58,7 @@ import "core-js/proposals/promise-with-resolvers";
"noLib": true,
"types": [
"typescript-baseline-lib",
"typescript-baseline-lib/allow/promise-withresolvers"
"typescript-baseline-lib/allow/promise-try"
]
}
}
Expand Down
Loading
Loading