Commit Graph

8304 Commits

Author SHA1 Message Date
Dominic Gannaway b67a29a8ab Merge remote-tracking branch 'upstream/master' into component-tree-hook-dev 2017-03-06 14:55:33 +00:00
Dominic Gannaway b572e3c907 moved non DEV methods to a new file called ReactFiberComponentTreeHook.js
This moves the non DEV methods to a new file called ReactFiberComponentTreeHook, updates existing references to DEV functions to remain inside DEV flags so they do not pull in ReactComponentTreeHook
2017-03-06 14:19:23 +00:00
Brandon Dail 12ad77d006 Remove EventPluginRegistry.getPluginModuleForEvent (#9110) 2017-03-06 00:52:56 -06:00
Brandon Dail 0c1f515faf Remove sliceChildren (#9109) 2017-03-06 00:52:39 -06:00
Brandon Dail ceafdbf0a5 Remove ReactStateSetters (#9107) 2017-03-03 22:42:25 -06:00
Dan Abramov d87c4d5e5c [Fiber] Don't schedule class fibers without relevant lifecycles for commit (#9105)
* Don't schedule class fibers without relevant lifecycles for commit

* Separate Update and Ref effects

* Simplify the exit condition

* Add missing annotation

* Write conditions differently to avoid an extra check

* Inline markUpdateIfNecessary()

* Inline markUpdateIfAlreadyInProgress()
2017-03-04 04:23:09 +00:00
Dima Beznos 0bedd0697a Added Brunch build tool to the docs (#9074)
* Added Brunch build tool to the docs

* Improved grammar

* product build -> production build
2017-03-03 16:15:25 -06:00
Andrew Clark ccde21cd2b Merge pull request #9088 from acdlite/testerrorutilsshim
Test that ReactErrorUtils module can be shimmed
2017-03-03 14:09:10 -08:00
Andrew Clark e3f6c850c2 Merge pull request #9097 from acdlite/dontextractprodproptypeerror
Fix production propTypes test so it works with error code system
2017-03-03 11:06:04 -08:00
Sasha Aickin fcf41e7ca2 Add async/await to unit tests; modify server rendering tests to use async/await. (#9089) 2017-03-03 10:34:14 -08:00
Andrew Clark fc4633775a Remove destructuring, since the version of node on www doesn't support it 2017-03-02 16:44:04 -08:00
Andrew Clark cf4c06ceba Merge pull request #9098 from acdlite/printwarnings
Add script to print out a list of warnings
2017-03-02 16:39:43 -08:00
Andrew Clark 673f514f81 Fix PropTypes production test so it works with error code system 2017-03-02 16:12:50 -08:00
Dominic Gannaway 91de17ec52 added guards in place to prevent mixed prod+dev errors from occuring 2017-03-02 23:06:32 +00:00
Dominic Gannaway 397fd2b92e removed double semicolon 2017-03-02 22:09:12 +00:00
Dominic Gannaway 9a1db49259 removed comment 2017-03-02 22:08:15 +00:00
Dominic Gannaway 1f7cbb63e8 updated flow annotations 2017-03-02 22:06:46 +00:00
Dominic Gannaway 54fef50186 re-added missing files 2017-03-02 21:52:54 +00:00
Dominic Gannaway da9d91829e WIP - not sure how to get the Flow type working properly 2017-03-02 21:50:02 +00:00
Sunny Ripert 179240ca30 Fix spacing in documentation (#9070)
Replace non-breaking space by space.
2017-03-02 13:57:58 -06:00
Jason Quense 2757a53fa5 Add fixture components (#8860)
* add fixture components

* add a few more options and styles

* Test fixture updates

- Pull in React from window global
- Add field to TestCase for fix PR links
- Update some styles

* Remove unused Fixture.Result comment

* Remove leading # from resolvedBy link

* Implement tag loading utility that caches response

Don't bust the cache doing feature detection

COME ON

* Use 'local' without version for option
2017-03-02 13:38:27 -06:00
Andrew Clark 9c8547cc9f Add script to print out a list of warnings
We'll use this in the GH sync script to track which warnings have
changed since the last sync
2017-03-02 11:37:01 -08:00
Dominic Gannaway e8f3f92a88 fixed flow issues and bug resulting in failing tests 2017-03-02 17:53:09 +00:00
Dominic Gannaway 0e23042e4b refactor of ReactComponentTreeHook to isolate dev methods 2017-03-02 16:15:37 +00:00
Vesa Laakso a190cfce29 Update Lifting State Up not to mix up DOM value with component state (#9032)
* Update Lifting State Up not to mix up DOM value with component state

A few weeks ago when teaching my friend, she got stuck on
`this.state.value` vs. `event.target.value`. As the documentation
talked a lot about "values", and the term value could mean three
different things (values in general, the "value" prop / DOM value of
the <input> component and the value in state/props), it was not weird
that she got a bit confused.

* Rename Lifting State Up onChange props to onTemperatureChange

This is in-line with how the temperature is provided as a prop named `temperature`

* Fix one value prop not being renamed to temperature

* Update codepen examples in Lifting state up documentation

* Update devtools state change to reflect docs change
2017-03-02 00:28:09 +00:00
Dan Abramov c8f14c26b0 Add a step to the release process 2017-03-01 22:56:06 +00:00
Andrew Clark b1a565f8fa Convert shorthanded syntax for function Flow types to expanded form
Something in www's test pipeline isn't able to parse this.
2017-03-01 14:38:48 -08:00
Andrew Clark a293d75f75 Test that ReactErrorUtils module can be shimmed
We do this in www
2017-03-01 14:38:48 -08:00
Andrew Clark 5881371b61 Merge pull request #9087 from acdlite/fixstringcasting
Fix string casting and remove Flow suppression comments
2017-03-01 13:51:17 -08:00
Sasha Aickin 3788654d57 Adding some server rendering unit tests. (#9055)
* Added a handful of SSR unit tests, ported from a previous pull request.

* Fixing linting errors

* Fixed a test helper function to properly report errors.

* Un-nested the new rendering tests. Updated the fiber test passing/not passing lists.

* Edited to comply with the react/jsx-space-before-closing eslint rule, which will soon be merged into master.

* Response to code review from @spicyj. Moved tests to separate file, reworked wording of test names, corrected use of canUseDom, and simplified tests against tagName. Thanks for the help, @spicyj!
2017-03-01 13:39:47 -08:00
Andrew Clark 5e5bc69230 Fix string casting and remove Flow suppression comments 2017-03-01 13:07:22 -08:00
Andrew Clark d1ee199492 Fix usage of Boolean constructor 2017-03-01 12:30:32 -08:00
Bryan Braun 7a878d27e3 Replace the header_links plugin with client-side generated anchors. (#4165)
* Replace the header_links plugin with client-side generated anchors.

Fixes facebook/react#4124

* Move anchor-link code into a separate script

Also adds a couple comments, for context.
2017-03-01 11:52:54 -08:00
Andrew Clark 737dac4f03 areChildrenOffscreen -> shouldDeprioritizeSubtree 2017-03-01 10:56:31 -08:00
Andrew Clark a1cd77db6e Pass type to areChildrenOffscreen, too 2017-03-01 10:56:31 -08:00
Andrew Clark 4602e768f3 Add areChildrenOffscreen to host config
Renderers can determine whether a node's children are offscreen based on
the host component's props. If so, they are given OffscreenPriority.

useSyncScheduling takes precedence.
2017-03-01 10:56:31 -08:00
Andrew Clark 4ef197b7d4 Check if we're in sync mode before deprioritizing hidden subtrees 2017-03-01 10:56:31 -08:00
Andrew Clark 81eef12507 Test that hidden subtrees render/update synchronously
When useSyncScheduling is set to true (as it is in the DOM renderer),
we shouldn't give OffscreenPriority to hidden subtrees. Everything
should be sync/task.
2017-03-01 10:56:31 -08:00
Andrew Clark 0585ee8b22 Merge pull request #9082 from acdlite/nobooleanorstringconstructors
Enforce no boolean or string constructors
2017-03-01 10:55:42 -08:00
Dominic Gannaway 18b86bc9d8 Merge pull request #9080 from trueadm/remove-stack-dependencies-from-tests
[Fiber] Remove stack dependencies from tests
2017-03-01 18:24:10 +00:00
Fokke Zandbergen 8eb7068364 Square renders button, not div (#9084) 2017-03-01 09:40:45 -06:00
Dominic Gannaway 8bc11649df Merge branch 'master' into remove-stack-dependencies-from-tests 2017-03-01 12:32:36 +00:00
Andrew Clark b963396c61 Run test script 2017-02-28 18:57:06 -08:00
Andrew Clark 7d5cc2eee3 Add test for no-primitive-constructors rule 2017-02-28 18:57:06 -08:00
Andrew Clark 2f63b0d6c9 Add error for number constructor, too 2017-02-28 18:57:06 -08:00
Andrew Clark b9c96cfc73 Add caveat about symbols to string error message 2017-02-28 18:57:06 -08:00
Andrew Clark 6ac5fd3c2b Rename rule to no-primitive-constructors 2017-02-28 18:57:06 -08:00
Andrew Clark 1e9812e31b Convert usage of String and Boolean constructors 2017-02-28 18:56:57 -08:00
Sebastian Markbåge e452e33741 providesModule -> explicit requires for cross-package dependencies (#9078)
* Add forwarding modules

* Codemod to use full package path outside of own package

Files that require modules from a different package than their own now
does so by the npm path name instead of the providesModule.

* Codemod fbjs module dependencies

* Fix gulp module mapping config

This is a bit lame but because of our module rewrite we need to white
list all the paths that we don't *don't* want to rewrite.
2017-02-28 18:42:52 -08:00
Andrew Clark 5f92d28e52 New ESLint rule that warns against Boolean and String constructors 2017-02-28 13:04:33 -08:00