Commit Graph
8484 Commits
Author SHA1 Message Date
Joel DenningandDan Abramov d3f84edcb6 Fixing the instantiation of customized builtin elements (related to custom elements) (#9313)
* Fixing the creation of customized builtin elements

* Whitespace

* Running prettier

* Updating ReactDOMFiberComponent
2017-04-19 12:07:16 +01:00
Fabrizio CastellarinandDan Abramov ff7baa4c95 Reorganize the "following along" instructions (#9453)
* Reorganize the "following along" instructions

* Minor tweaks
2017-04-19 12:00:15 +01:00
Ben AlpertandGitHub 55eeb6c403 Fix errors in React Native children management (#9449)
* Fix errors in React Native children management

- Support using appendChild to move an existing child (Fiber does this, but we were assuming all children here were new; Yoga throws if you insert a child that already has a parent)
- Calculate beforeChildIndex after removing old child (previously, off by one when the new position is later than the old position)

* Add better children management tests for RN
2017-04-18 17:31:33 -07:00
Filip HoškoandDan Abramov ab483f49df FIX: Move CRA build info under it's tab page (#9452)
* FIX: Move CRA build info under it's tab page

* Add some links
2017-04-18 18:17:28 +01:00
Dan Abramov a7e7e5054b Tweak tutorial structure 2017-04-18 18:07:16 +01:00
Dan Abramov 8e861af293 Add missing tutorial sidebar links 2017-04-18 18:00:54 +01:00
Dan Abramov 8798c9f08b Minor tutorial nits 2017-04-18 17:53:53 +01:00
Dan Abramov b97d51af57 Fix duplicate sentence 2017-04-18 17:44:32 +01:00
Dan AbramovandGitHub 7415729e55 Minor tweaks to tutorial 2017-04-18 17:40:59 +01:00
Frankie BagnardiandDan Abramov e2846ee6d0 [Tutorial] ES6, installation, and button closing tag (#9441)
* adds notes to tutorial on es6 and installation

* fixes tutorial mention of opening button tag

* More writing

* Update
2017-04-18 17:34:43 +01:00
Abhishek SoniandDan Abramov 70ebda7630 Fixed grammar (#9432)
* Update codebase-overview.md

* Some more fixes
2017-04-18 16:38:39 +01:00
hanumanthanandDan Abramov 5689096e92 Lift state up - Updating the documentation to mention that onClick is a synthetic event handler (#9427)
* Lift state up - Updating the documentation to mention that onClick is a synthetic event handler

* Review comments - Rephrase to handle synthetic events and event handler patterns

* Tweak
2017-04-18 16:27:45 +01:00
Michał OrdonandDan Abramov 8a54de60c8 Sort out conferences by date (#9172) 2017-04-18 15:38:19 +01:00
Jayen AsharandDan Abramov b292ccc940 Update jsx-in-depth.md (#9178)
* Update jsx-in-depth.md

Line 9 isn't changed

* Move selection down

* Fix
2017-04-18 15:29:17 +01:00
Fraser HaerandDan Abramov 0146b3d361 Unique headings for linking purposes (#9259)
Previously two headings were 'Javascript Expressions' - now 'Javascript
Expressions as Props' and 'Javascript Expressions as Children'
2017-04-18 14:47:44 +01:00
NE-SmallTownandDan Abramov c21c9ae7b9 [Documentation] Impreove the react-component section of doc (#9349)
* Impreove react-component of doc 

[#9304](https://github.com/facebook/react/issues/9304)

* update description

* add missing space
2017-04-18 14:42:40 +01:00
Chris PearceandDan Abramov 8dc003f776 Only attempt to clear measures if we created the measure (#9451)
This fixes an issue where if we decided not to create a measurement we would clear ALL measurements from the performance entry buffer due to passing `undefined` as the entry name.
2017-04-18 14:31:47 +01:00
Sung Won ChoandDominic Gannaway 788bbab563 Make nodeType into constant for readability and reuse (#9113)
* Make nodeType into constant for readability and reuse

* Fix eslint line length warning

* Delete unused nodeType values

* Destructure HTMLNodeType constant

* Make nodeType into constant for readability and reuse

* Fix eslint line length warning

* Delete unused nodeType values

* Destructure HTMLNodeType constant

* Fix test

* Format using prettier
2017-04-15 18:37:12 +01:00
Ben AlpertandGitHub 7fa0376fbc Add component stack to ReactControlledValuePropTypes (#9435) 2017-04-14 19:50:43 -07:00
Ben AlpertandGitHub 309ad21b70 Add component stack to uncontrolled-to-controlled warning (#9416)
https://twitter.com/JulianVModesto/status/836089555304448000
https://twitter.com/abevoelker/status/836040051993763842
2017-04-14 16:57:47 -07:00
Arshabh Kumar AgarwalandBrandon Dail fd58a81aef Add warning if rendering and HTMLUnknownElement (#9163)
* Add warning if rendering and HTMLUnknownElement

* Records fiber tests

* Fixes linting and server render tests

* Incorporates review comments

* Uses ownerDocument instead of document

* uses el instead of creating a new element

* Removes warning check of voidElementTags

* Add missing space to unknown element warning

* Only call isCustomComponent once

* Spy on console in menuitem test

Since menuitem is treated as an unknown element in jsdom it triggers the unknown element warning.

* Add unknown element warning to Fiber

* Replace instanceof with toString check

It is more resilient.

* Record tests
2017-04-14 11:30:38 -05:00
Abhay NikamandBrandon Dail 4b62eafd54 Updated the Good First Bug section in readme (#9429)
* Updated the Good First Bug section in readme

* Inconsistent use of quotes. Prefered single quotes instead of double quotes

* Updated Good first bug link in how_to_contribute doc.

* Undo JSX attribute quote change

* don't capitalize "beginner friendly issue"
2017-04-14 11:02:07 -05:00
Vikash AgrawalandBrandon Dail e7e1787a71 Updated link for good first bug's in README.md (#9273)
* Updated link for good first bug's in README.md

* Changed text for beginner friendly bugs

* update beginner friendly bugs section title
2017-04-14 10:56:38 -05:00
Abhay NikamandDan Abramov f66ad13e94 Updated recommended links for installation in readme (#9425) 2017-04-13 23:15:13 +01:00
Dan AbramovandGitHub 7bb5933dc0 Switch Installation to a tab when hash is present (#9422) 2017-04-13 21:51:19 +01:00
Marks PolakovsandDan Abramov 4fd9b67429 Add tabs to installation page (#9275, #9277) (#9401)
* Add tabs to installation page (#9275, #9277)

This adds tabs for create-react-app and existing apps to the installation section of the docs. The tab implementation is a simplified version of React Native's installation page.

Fixes #9275.

* Use classList instead of className

* Use same implementation as in RN
2017-04-13 20:54:12 +01:00
Eric ElliottandDan Abramov cc14bb268b Docs: Clarification of setState() behavior (#9329)
* Clarification of setState() behavior

`setState()` is a frequent source of confusion for people new to React, and I believe part of that is due to minimization of the impact of the asynchronous behavior of `setState()` in the documentation. This revision is an attempt to clarify that behavior. For motivation and justification, see [setState Gate](https://medium.com/javascript-scene/setstate-gate-abc10a9b2d82).

* Update reference-react-component.md

* Signature fix

* Update to address @acdlite concerns

* Add more details
2017-04-13 19:13:55 +01:00
JackandDan Abramov fc55c8d2fd Update proptypes doc (#9391)
* Update proptypes doc

* Removed note
2017-04-13 18:11:23 +01:00
Gabriel Lett VivianiandDan Abramov 77b03e18f8 Fix the proptypes deprecation warning url on the "Don't Call PropTypes Warning" doc page (#9419)
* Use the same prop-types link on the warning docs page as the main proptypes doc page

* Link to repo instead
2017-04-13 15:15:34 +01:00
hanumanthanandDan Abramov 646af34a84 Refractor docs to indicate that state set to props in constructor will not recieve the updated props (#9404) 2017-04-13 00:56:22 +01:00
Dominic GannawayandDan Abramov 33ec3f53f2 Update typechecking-with-proptypes.md (#9392)
* Update typechecking-with-proptypes.md

* Update typechecking-with-proptypes.md

* Use consistent style for PropTypes import
2017-04-12 00:04:38 +01:00
Brian Vaughn bcb3052f2b Bumped versions for 16.0.0-alpha.9 and re-built 2017-04-11 14:40:56 -07:00
Brian VaughnandGitHub 97e8fbaeea createClass + PropTypes + checkPropTypes warnings (#9399)
(Temporarily) re-adds getters with deprecation warnings for React.PropTypes, React.checkPropTypes, and React.createClass.

* 08bd020: Replace all references to React.PropTypes with prop-types to avoid triggering our own warning message.
* ef5b5c6: Removed several references to React.createClass that appeared after rebasing this branch. (reviewed by @flarnie)
* 524ce20: Added getters for createClass and PropTypes to the main React isomorphic object, behind one-time warning messages. (reviewed by @spicyj)
* db48f54: Fixed Rollup bundles to inline 'prop-types' and 'create-react-class' for UMD builds only. (reviewed by @spicyj, @trueadm )
* cf49cfd: Updated tests-passing.txt to remove tests that were deleted in this branch.
* d34109a: Responses to PR feedback from @spicyj. (Added package.json dependencies to packages/react and packages/react-dom. Renamed a var. Expanded on an inline comment.)
* 488c8d2: Added warning for moved package to React.checkPropTypes accessor too and updated build script.
* 83bcb29: Wordsmithing for deprecation notices (added fb.me links).
* afdc9d2: Tweaked legacy module inlining to remove order-of-deps constraint
* d1348b9: Removed $FlowFixMe.
* 7dbc3e7: More wordsmithing of deprecation notices based on Dan's feedback.
2017-04-11 14:28:03 -07:00
Dan Abramov 0ec8771384 Use caret range in blog instructions
The release was a bit broken.
2017-04-11 22:04:29 +01:00
Denis PismennyandDan Abramov 123295242e Fix minor typo in lifting-state-up.md (#9408) 2017-04-11 22:03:53 +01:00
Ben AlpertandGitHub d0b61291f3 Fix ignore patterns in package.json (#9409) 2017-04-11 13:58:14 -07:00
Andrew Clark 9ea29e3e5c react-create-class -> create-react-class 2017-04-10 17:06:32 -07:00
Andrew Clark 798c506d5e Add react-create-class integration tests
These are mostly copied from the old ReactClass-test module.
2017-04-10 17:03:05 -07:00
Andrew Clark c55352076b Convert createClass caller
This snuck in after rebasing
2017-04-10 17:03:05 -07:00
Andrew Clark 7ad5b5481d Warn once when attempting to access React.createClass
Should still be undefined.
2017-04-10 17:03:05 -07:00
Andrew Clark 6ff1622105 Run prettier 2017-04-10 17:03:05 -07:00
Andrew Clark d32060039d Update tests to use plain JavaScript classes
Tests that rely on replaceState or isMounted use
updater.enqueueReplaceState and updater.isMounted instead.
2017-04-10 17:03:05 -07:00
Andrew Clark 6071721e7b Rewrite Stack implementation of ReactART using plain classes
instead of createClass
2017-04-10 17:03:05 -07:00
Andrew Clark 63e8bf02ad Delete createClass
Remove createClass from isomorphic package
2017-04-10 17:03:05 -07:00
Maciej KasprzykandBrandon Dail f1c5f59b3c Delete examples dir from codebase overview (#9397)
Removes doc about folder that no longer exists.
2017-04-10 16:26:09 -05:00
Dan AbramovandGitHub 6a9c9e2acb Fix ReactARTStack bundles to not include DOM Stack inside (#9394)
* Move ReactDOMFrameScheduling.js to shared (between dom and art)

* Fix ReactARTStack bundles to not include DOM Stack inside
2017-04-10 22:01:56 +01:00
Luke BelliveauandBrandon Dail 1eebc56f1f Amended implementation-notes.md with link to Dan Abramov's post describing difference between React components, elements, and instances (#9388)
* Amended implementation-notes.md to include a link to a blog post by Dan Abramov, explaining the difference between components, elements, and instances. An understanding of this distinction is crucial in tracing through Implementation pseudocode, and reading Dan's blog first may ease newcomers into understanding the implementation.

* adjusted wording to maintain stylistic consistency with rest of content, per @aweary's request
2017-04-09 14:37:41 -05:00
Aaron AckermanandDan Abramov 50bebb19c0 Point users to the npm page instead of the github project for prop-types (#9373) 2017-04-08 04:05:34 +01:00
Andrew ClarkandGitHub d2cd56472a Blog post and changelog for 15.5.0 (#9368) 2017-04-07 14:41:16 -07:00
Dan AbramovandGitHub ec2e2b70c7 Replace shims with explicit React access from the renderers for shared global state (#9366)
* Remove non-existent /lib/ from souce files

* Replace all shims with explicit access

This deletes shims and changes to access require('react').__DO_NOT_USE__ from renderers for global shared state.

I cloned flattenChildren() and traverseAllChildren() because they relied on CurrentOwner but were used both from Stack and Isomorphic. The stack implementations will die, and the isomorphic ones can be changed to be optimized for Children specifically in the future.

I also deleted UMD shims because they are now unnecessary. I moved the internals assignment to main modules since they're now used in tests, and made them direct UMD entry points.
2017-04-07 22:07:10 +01:00