Skip to content

merge upstream master #57

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 65 commits into from
Mar 11, 2019
Merged

merge upstream master #57

merged 65 commits into from
Mar 11, 2019

Conversation

joeycozza
Copy link

No description provided.

ricokahler and others added 30 commits February 1, 2019 17:49
As a lot of [people](https://hackernoon.com/why-i-no-longer-use-typescript-with-react-and-why-you-shouldnt-either-e744d27452b4) is complaining about TypeScript performance in CRA, I decided to enable `async` mode in TypeScript checker.

These changes basically brings the JS compilation times to TS projects. So, recompilation took less than 1 second instead of 3 seconds in medium size project.

The problem with async mode is that type-errors are reported after Webpack ends up recompilation as TypeScript could be slower than Babel. PR allows to emit files compiled by Babel immediately and then wait for TS and show type errors in terminal later. Also, if there was no compilation errors and any type error occurs, we trigger a hot-reload with new errors to show error overlay in browser.

Also, I wanted to start a discussion about `skipLibCheck: false` option in default `tsconfig.json`. This makes recompilations really slow and we should consider to set it to `true` or at least give users a big warning to let them know that it could be really slow.

The following video is showing the updated workflow with a forced 2.5 second delay for type-check to give you an idea how it works.

![nov-26-2018 15-47-01](https://user-images.githubusercontent.com/5549148/49021284-9446fe80-f192-11e8-952b-8f83d77d5fbc.gif)


I'm pretty sure that PR needs some polishing and improvements but it should works as it is. Especially a "hack" with reloading the browser after type-check looks ugly to me.

cc @brunolemos as he is an initiator of an original TypeScript PR.

Should fix #5820
Sass source map for dev
As part of the latest babel-plugin-macros [2.4.5 release](https://github.com/kentcdodds/babel-plugin-macros/releases/tag/v2.4.5), there was a small fix that went in that fixes a [bug](kentcdodds/babel-plugin-macros#100) specifying the `babelMacros` entry in `package.json` no longer working. This patch version increase should remedy the issue and allow specifying babel macro configuration in the `package.json` file again (as stated in the [user docs](https://github.com/kentcdodds/babel-plugin-macros/blob/master/other/docs/user.md#config-experimental) of babel-plugin-macros)
* [docs] Warn about storing secrets in env vars

Fixes #5676

Co-Authored-By: Ian Schmitz <ianschmitz@gmail.com>

* [docs] Add NOT to REACT_APP_SECRET_CODE

Fixes #5676

* [docs] Remove line breaks
* Add Jest typeahead plugin

* Update jest-watch-typeahead to 0.2.1
* Update docs links to prefer HTTPS for supported domains

* Fix existing typos
 - babel-plugin-named-asset-import@0.3.1
 - babel-preset-react-app@7.0.1
 - create-react-app@2.1.4
 - eslint-config-react-app@3.0.7
 - react-app-polyfill@0.2.1
 - react-dev-utils@7.0.2
 - react-error-overlay@5.1.3
 - react-scripts@2.1.4
 - create-react-app@2.1.5
 - react-dev-utils@7.0.3
 - react-scripts@2.1.5
Upgrade Docusaurus and enable new features
* Add forward ref to SVG component

* Write proper component for the ref test

* Add ref to jest svg transform and fix tests

* Fix SVG file location

* Use proper `ref` instead of svgRef in tests

* Add ref to svgr loader
leighhalliday and others added 29 commits February 19, 2019 09:25
The current `analyze` script only analises the `/src` code. This change leverages new version of `source-map-explorer` that is able to analyse multiple bundles at once, including the  3rd party dependencies bundle which is in my opinion even more important to analyze.
minor typo fix in openBrowser
* Improved language used in code blocks.
The enabled by default statement made sense when the developer was supposed to disable flow in order to use ts. Both those statements in there create some confusion about it in my opinion.
 - babel-preset-react-app@7.0.2
 - confusing-browser-globals@1.0.6
 - create-react-app@2.1.6
 - eslint-config-react-app@3.0.8
 - react-app-polyfill@0.2.2
 - react-dev-utils@7.0.4
 - react-error-overlay@5.1.4
 - react-scripts@2.1.6
 - create-react-app@2.1.7
 - react-dev-utils@7.0.5
 - react-scripts@2.1.7
 - create-react-app@2.1.8
 - react-dev-utils@8.0.0
 - react-scripts@2.1.8
* Upgrade webpack-dev-server to 3.2.1
* reattempt changes

* formatter fixes

* fix missing colon in path

* revert path tweaking amends as per discussion with @ianschmitz
* change class component to function component

* Update packages/react-scripts/template/src/App.js

Co-Authored-By: xiaoxiangmoe <xiaoxiangmoe@gmail.com>

* Update packages/react-scripts/template-typescript/src/App.tsx

Co-Authored-By: xiaoxiangmoe <xiaoxiangmoe@gmail.com>
compiler is not being reassigned, so we can use a const here
@joeycozza joeycozza merged commit 1b5aa70 into fs-webdev:master Mar 11, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.