This repository was archived by the owner on Nov 16, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 227
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Revert note about declarationDir. Update ts to the latest version
- Loading branch information
1 parent
1efbdf4
commit b060934
Showing
3 changed files
with
30 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -36,26 +36,26 @@ npm run type-check -- --watch | |
Either run the following: | ||
|
||
```sh | ||
npm install --save-dev typescript@2.7.2 | ||
npm install --save-dev @babel/[email protected].44 | ||
npm install --save-dev @babel/[email protected].44 | ||
npm install --save-dev @babel/[email protected].44 | ||
npm install --save-dev @babel/[email protected].44 | ||
npm install --save-dev @babel/[email protected].44 | ||
npm install --save-dev @babel/[email protected].44 | ||
npm install --save-dev typescript@2.9.1 | ||
npm install --save-dev @babel/[email protected].49 | ||
npm install --save-dev @babel/[email protected].49 | ||
npm install --save-dev @babel/[email protected].49 | ||
npm install --save-dev @babel/[email protected].49 | ||
npm install --save-dev @babel/[email protected].49 | ||
npm install --save-dev @babel/[email protected].49 | ||
``` | ||
|
||
or make sure that you add the appropriate `"devDependencies"` entries to your `package.json` and run `npm install`: | ||
|
||
```json | ||
"devDependencies": { | ||
"@babel/cli": "^7.0.0-beta.44", | ||
"@babel/core": "^7.0.0-beta.44", | ||
"@babel/plugin-proposal-class-properties": "^7.0.0-beta.44", | ||
"@babel/plugin-proposal-object-rest-spread": "^7.0.0-beta.44", | ||
"@babel/preset-env": "^7.0.0-beta.44", | ||
"@babel/preset-typescript": "^7.0.0-beta.44", | ||
"typescript": "^2.8.1" | ||
"@babel/cli": "^7.0.0-beta.49", | ||
"@babel/core": "^7.0.0-beta.49", | ||
"@babel/plugin-proposal-class-properties": "^7.0.0-beta.49", | ||
"@babel/plugin-proposal-object-rest-spread": "^7.0.0-beta.49", | ||
"@babel/preset-env": "^7.0.0-beta.49", | ||
"@babel/preset-typescript": "^7.0.0-beta.49", | ||
"typescript": "^2.9.1" | ||
} | ||
``` | ||
|
||
|
@@ -67,6 +67,8 @@ Then run | |
tsc --init --declaration --allowSyntheticDefaultImports --target esnext --outDir lib | ||
``` | ||
|
||
**Note:** TypeScript also provides a `--declarationDir` option which specifies an output directory for generated declaration files (`.d.ts` files). For our uses where `--emitDeclarationOnly` is turned on, `--outDir` works equivalently. | ||
|
||
## Create your `.babelrc` | ||
|
||
Then copy the `.babelrc` in this repo, or the below: | ||
|
@@ -105,7 +107,7 @@ Install the [@babel/preset-react](https://www.npmjs.com/package/@babel/preset-re | |
|
||
```sh | ||
npm install --save react react-dom @types/react @types/react-dom | ||
npm install --save-dev @babel/[email protected].44 | ||
npm install --save-dev @babel/[email protected].49 | ||
``` | ||
|
||
### Update `.babelrc` | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters