Commit Graph
1187 Commits
Author SHA1 Message Date
Dan AbramovandGitHub 822f4cdc04 Ignore react-native-web in Flow checks (#17999) 2020-02-07 16:24:25 +00:00
Dominic GannawayandGitHub 985a2438fc Add feature flag for removing children Map support (#17990) 2020-02-06 13:19:35 +00:00
Dominic GannawayandGitHub d4bc2f4673 Use babel parser rather than Babylon in extract errors (#17988) 2020-02-06 12:46:32 +00:00
f2e6061ff6 Updated release script documentation and command names (#17929)
* Updated release script documentation and command names

* Update scripts/release/README.md

Co-Authored-By: Sunil Pai <[email protected]>

* Updated README

Co-authored-by: Sunil Pai <[email protected]>
2020-02-05 08:52:31 -08:00
Brian Vaughn de9d449430 Formatting fix (Prettier) to build script 2020-02-04 11:37:38 -08:00
Brian VaughnandGitHub 85d7397c6b Fix release scripts (#17972)
Circle CI seems to have changed the reported artifact path which broke our scripts.
2020-02-04 11:36:49 -08:00
Sunil PaiandGitHub c5d9782838 make testing builds for React/ReactDOM (#17915)
This PR introduces adds `react/testing` and `react-dom/testing`.
- changes infra to generate these builds
- exports act on ReactDOM in these testing builds
- uses the new test builds in fixtures/dom

In the next PR -

- I'll use the new builds for all our own tests
- I'll replace usages of TestUtils.act with ReactDOM.act.
2020-02-03 23:31:31 +00:00
Dan AbramovandGitHub c6286948da Add a note about expiring OTP codes 2020-01-29 16:31:51 +00:00
Dan AbramovandGitHub 075664a3fd Use next tag for canary releases in the doc (#17923) 2020-01-29 16:09:05 +00:00
Dan AbramovandGitHub 712d1be33f Fix Jest diff call (#17921) 2020-01-29 14:38:22 +00:00
Simen BekkhusandNicolas Gallagher 626c0fd9d7 Upgrade to jest 25 (#17896)
The changes to the test code relate to changes in JSDOM that come with Jest 25:

* Several JSDOM workarounds are no longer needed.
* Several tests made assertions to match incorrect JSDOM behavior (e.g. setAttribute calls) that JSDOM has now patched to match browsers.
  * https://codesandbox.io/s/resets-value-of-datetime-input-to-fix-bugs-in-ios-safari-1ppwh
* JSDOM no longer triggers default actions when dispatching click events.
  * https://codesandbox.io/s/beautiful-cdn-ugn8f
* JSDOM fixed (jsdom/jsdom#2700) a bug so that calling focus() on an already focused element does not dispatch a FocusEvent.
* JSDOM now supports passive events.
* JSDOM has improved support for custom CSS properties.
  * But requires jsdom/cssstyle#112 to land to support webkit prefixed properties.
2020-01-25 08:43:02 -08:00
Nicolas GallagherandGitHub 20bbe0701c Update to flow 0.97 (#17892) 2020-01-24 10:52:38 -08:00
Nicolas GallagherandGitHub 617cc1c4ef Remove unused modules from legacy event responders (#17907) 2020-01-24 10:50:27 -08:00
Nicolas GallagherandGitHub 77f7835a5f Update to [email protected] (#17842) 2020-01-22 10:02:30 -08:00
Dominic GannawayandGitHub b920ab6d91 Add unstable_renderSubtreeIntoContainer and unstable_createPortal feature flags (#17880) 2020-01-21 21:17:42 +00:00
Dominic GannawayandGitHub df9668c5f1 Remove ReactInstanceMap_DO_NOT_USE shim (#17861) 2020-01-17 12:37:55 +00:00
Nicolas GallagherandGitHub 7efac90a17 Update typescript package and jest preprocessor (#17839) 2020-01-14 13:52:52 -08:00
Nicolas GallagherandGitHub 2155d6381f Update babel-eslint and eslint packages (#17829) 2020-01-14 09:26:44 -08:00
EmilyandBrian Vaughn a2677e9133 Create ReactFabric.stopSurface and use that for bridgeless mode binding (#16164) 2020-01-10 10:21:32 -08:00
Dan AbramovandGitHub fe1bbbae20 Update Flow to 0.84 (#17805)
* Update Flow to 0.84

* Fix violations

* Use inexact object syntax in files from fbsource

* Fix warning extraction to use a modern parser

* Codemod inexact objects to new syntax

* Tighten types that can be exact

* Revert unintentional formatting changes from codemod
2020-01-09 14:50:44 +00:00
Dan AbramovandGitHub 6e9c0d3038 Bump Prettier (#17811)
* Bump Prettier

* Reformat

* Use non-deprecated option
2020-01-09 13:54:11 +00:00
Brian VaughnandGitHub ea2add157f Renamed "ReactDOM-fb" imports to "ReactDOM" in www shims (#17797)
* Renamed "ReactDOM-fb" imports to "ReactDOM" in www shims

* Removed ReactDOMComponentTree_DO_NOT_USE.js
2020-01-07 13:05:36 -08:00
Brian VaughnandGitHub c167238cb1 Fixed CircleCI DevTools build artifact tar internal structure (#17758) 2020-01-02 09:28:20 -08:00
Brian VaughnandGitHub 0bfa14e06b Build and store DevTools artifacts in Circle CI (#17746) 2020-01-01 07:58:47 -08:00
Karan SharmaandBrian Vaughn cc793eb2b4 Fix various typos (#17724) 2019-12-29 13:47:51 -08:00
Nicolas GallagherandGitHub a2ad75cd4e Add unit tests to dom-event-testing-library (#17680)
Unit tests for the simple event mocks
2019-12-20 16:35:02 +00:00
Brian VaughnandGitHub cfbe4cbe6a DevTools build script enhancements (#17653)
* Updated DevTools local development instructions to mention experimental build step

* Added a command to download latest experimental release (for DevTools)

* Updated build instructions for clarity

* Added build-for-devtools package alias
2019-12-18 14:34:40 -08:00
Dan AbramovandGitHub 82a3bce9be Build FB RN targets only in experimental mode (#17641) 2019-12-17 20:22:49 +00:00
Dan AbramovandGitHub 1407340157 Additional test infra changes for toErrorDev rename (#17632) 2019-12-17 13:31:47 +00:00
Dan AbramovandBrian Vaughn ccee948f06 Fix test_build_devtools CI job to run test-build-devtools (#17631)
* Skip abandoned project folders in Jest config

This fixes a problem that occurs after renaming a package.

* Fix test_build_devtools to run test-build-devtools

* Exclude console.error plugin for DevTools packages

* Use correct release channel for DevTools tests

This should fix the createRoot error.

* Fix TZ dependent test

* Change DT job dependencies
2019-12-16 16:03:12 -08:00
Dan Abramov 1c6f7c3ac3 Fix release script to ignore empty package folders 2019-12-16 19:16:58 +00:00
Dan AbramovandGitHub 0809ba8020 Rename toWarnDev -> toErrorDev, toLowPriorityWarnDev -> toWarnDev (#17605)
* Rename toWarnDev -> toErrorDev in tests

* Rename toWarnDev matcher implementation to toErrorDev

* Rename toLowPriorityWarnDev -> toWarnDev in tests and implementation
2019-12-16 12:48:16 +00:00
Dan AbramovandGitHub d90d691d4a Use console directly instead of warning() modules (#17599)
* Replace all warning/lowPriWarning with console calls

* Replace console.warn/error with a custom wrapper at build time

* Fail the build for console.error/warn() where we can't read the stack
2019-12-14 18:09:25 +00:00
Laura bunsandDan Abramov 96b5edde35 Remove the condition argument from warning() (#17568)
* prep for codemod

* prep warnings

* rename lint rules

* codemod for ifs

* shim www functions

* Handle more cases in the transform

* Thanks De Morgan

* Run the codemod

* Delete the transform

* Fix up confusing conditions manually

* Fix up www shims to match expected API

* Also check for low-pri warning in the lint rule
2019-12-11 03:28:14 +00:00
Laura bunsandDan Abramov 0cee996ff7 Replace wrap-warning-with-env-check with an eslint plugin (#17540)
* Replace Babel plugin with an ESLint plugin

* Fix ESLint rule violations

* Move shared conditions higher

* Test formatting nits

* Tweak ESLint rule

* Bugfix: inside else branch, 'if' tests are not satisfactory

* Use a stricter check for exactly if (__DEV__)

This makes it easier to see what's going on and matches dominant style in the codebase.

* Fix remaining files after stricter check
2019-12-06 18:25:54 +00:00
Andrew ClarkandGitHub c04f95f33b Update release script URL (#17428)
CircleCI API endpoint changed
2019-11-21 13:19:03 -08:00
Sebastian MarkbågeandGitHub d299841577 [Flight] Move Flight DOM to a Webpack Specific Package (#17372)
* Move Flight DOM to Webpack Specific Packagee

We'll have Webpack specific coupling so we need to ensure that it can be
versioned separately from various Webpack versions. We'll also have builds
for other bundlers in the future.

* Move to peerDep

* Move DOM Flight Tests

* Merge ReactFlightIntegration into ReactFlightDOM

This was an integration test. We can add to it.

* Fix fixture paths
2019-11-15 11:46:07 -08:00
Eli WhiteandGitHub b89260af5a [Native] Add FeatureFlag to dispatch events with instance targets (#17323)
* [Native] Add FeatureFlag to dispatch events with instance targets

* Prettier
2019-11-11 11:35:29 -08:00
Dan AbramovandGitHub d4bcb84d9f Add yarn build --unsafe-partial (#17316)
* Add yarn build --partial

* unsafe-partial
2019-11-08 19:41:40 +00:00
Moti ZilbermanandGitHub 53c7208c33 Update deepDiffer usage in React Native renderer (#17282)
* Add RN prop diffing test with function values

* Update RN deepDiffer mock

* Explicitly ignore functions in RN prop differ
2019-11-07 04:00:20 -08:00
Sebastian MarkbågeandGitHub 4d82f9ae2e [Flight] Move around the Server side a bit (#17251)
* Rename ReactFlightStreamer -> ReactFlightServer

* Unify Browser/Node stream tests into one file and use the client reader

* Defer to the actual ReactDOM for HTML rendering for now

This will need to use a variant of Fizz to do inline SSR in Flight.
However, I don't want to build the whole impl right now but also don't
want to exclude the use case yet. So I outsource it to the existing
renderer. Ofc, this doesn't work with Suspense atm.
2019-11-01 17:39:24 -07:00
Sebastian MarkbågeandGitHub 0682838503 [Flight] Add Client Infrastructure (#17234)
* Change demo to server

* Expose client in package.json

* Reorganize tests

We don't want unit tests but instead test how both server and clients work
together. So this merges server/client test files.

* Fill in the client implementation a bit

* Use new client in fixture

* Add Promise/Uint8Array to lint rule

I'll probably end up deleting these deps later but they're here for now.
2019-11-01 16:05:07 -07:00
Sebastian MarkbågeandGitHub db3b753ef0 Add Experimental Flight Infrastructure (#16398)
* Add Flight Build and Unify HostFormat Config between Flight and Fizz

* Add basic resolution of models

* Add basic Flight fixture

Demonstrates the streaming protocol.

* Rename to flight-server to distinguish from the client parts

* Add Flight Client package and entry point

* Fix fixture
2019-10-29 14:45:47 -07:00
Andrew ClarkandGitHub d33155596e Experimental test helper: it.experimental (#17149)
Special version of Jest's `it` for experimental tests. Tests marked as
experimental will run **both** stable and experimental modes. In
experimental mode, they work the same as the normal Jest methods. In
stable mode, they are **expected to fail**. This means we can detect
when a test previously marked as experimental can be un-marked when the
feature becomes stable. It also reduces the chances that we accidentally
add experimental APIs to the stable builds before we intend.

I added corresponding methods for the focus and skip APIs:

- `fit` -> `fit.experimental`
- `it.only` -> `it.only.experimental` or `it.experimental.only`
- `xit` -> `xit.experimental`
- `it.skip` -> `it.skip.experimental` or `it.experimental.skip`

Since `it` is an alias of `test`, `test.experimental` works, too.
2019-10-19 16:08:08 -07:00
Andrew ClarkandGitHub ff519a3c1b Build script should default to experimental (#17144)
`yarn build` defaults to building in experimental mode. To opt-out, set
the `RELEASE_CHANNEL` environment variable to `stable`. This is the same
as what we do when running tests via `yarn test`, to make local
development easier.
2019-10-18 19:35:33 -07:00
Andrew ClarkandGitHub d6f4ee820f Add experimental instructions to release README (#17143) 2019-10-18 16:26:06 -07:00
Andrew ClarkandGitHub f3cd676432 Don't build non-experimental www bundles (#17139)
Reduces the likelihood we'll accidentally sync the wrong ones.
2019-10-18 14:36:59 -07:00
Dan AbramovandGitHub 60e8db47d7 Update RN typings for a shim (#17138) 2019-10-18 18:05:09 +01:00
Andrew ClarkandGitHub 864bcb7d94 Separate sizebot for experimental builds (#17100)
Configures the sizebot to leave a second comment that tracks the
experimental build artifacts.
2019-10-15 18:43:06 -07:00
Andrew ClarkandGitHub 7c0e54af2f Remove concurrent apis from stable (#17088)
* Tests run in experimental mode by default

For local development, you usually want experiments enabled. Unless
the release channel is set with an environment variable, tests will
run with __EXPERIMENTAL__ set to `true`.

* Remove concurrent APIs from stable builds

Those who want to try concurrent mode should use the experimental
builds instead.

I've left the `unstable_` prefixed APIs in the Facebook build so we
can continue experimenting with them internally without blessing them
for widespread use.

* Turn on SSR flags in experimental build

* Remove prefixed concurrent APIs from www build

Instead we'll use the experimental builds when syncing to www.

* Remove "canary" from internal React version string
2019-10-15 15:09:19 -07:00