1
0
mirror of https://github.com/ianstormtaylor/slate.git synced 2025-09-01 19:22:35 +02:00

docs: TypeScript is now a latest release so removed mention of installing @next release in TypeScript docs

This commit is contained in:
Sunny Hirai
2021-03-29 18:05:07 -07:00
parent ca74eef1a3
commit e81acf5841

View File

@@ -1,17 +1,9 @@
# TypeScript # TypeScript
Extended TypeScript support is currently available in the `@next` release of Slate only but should be a regular release soon. You will need to install it before using.:
```sh
# for npm
npm install --save slate@next slate-react@next slate-history@next
# for yarn
yarn add slate@next slate-react@next slate-history@next
```
Slate supports typing of one Slate document model (eg. one set of custom `Editor`, `Element` and `Text` types). Slate supports typing of one Slate document model (eg. one set of custom `Editor`, `Element` and `Text` types).
You must define `CustomTypes` when using TypeScript or Slate will display typing errors.
If you need to support more than one document model, see the section Multiple Document Models. If you need to support more than one document model, see the section Multiple Document Models.
## Defining `Editor`, `Element` and `Text` Types ## Defining `Editor`, `Element` and `Text` Types