Skip to content
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

Fix ReactiveDependencies rule #3

Closed
wants to merge 152 commits into from

Commits on Oct 31, 2018

  1. Configuration menu
    Copy the full SHA
    cdbfa6b View commit details
    Browse the repository at this point in the history

Commits on Nov 1, 2018

  1. Simplify imports in react reconciler (facebook#13718)

    * Simplify imports in ReactChildFiber
    * Import type first in ReactCurrentFiber
    * Simplify imports in ReactFiberBeginWork
    * Simplify imports in ReactFiberScheduler
    * Simplify import in ReactFiberTreeReflection
    * Simplify import in ReactFiberUnwindWork
    * Remove repeated import
    * Fix imports from ReactFiberExpirationTime
    * Master imports in ReactFiberBeginWork
    mmarkelov authored and nhunzaker committed Nov 1, 2018
    Configuration menu
    Copy the full SHA
    d5d10d1 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    595b4f9 View commit details
    Browse the repository at this point in the history

Commits on Nov 2, 2018

  1. Configuration menu
    Copy the full SHA
    c84b9bf View commit details
    Browse the repository at this point in the history
  2. Warn for forwardRef(memo(...)) (facebook#14070)

    People are probably gonna do this all the time.
    sophiebits committed Nov 2, 2018
    Configuration menu
    Copy the full SHA
    c898020 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    ae196e8 View commit details
    Browse the repository at this point in the history
  4. Warn for bad useEffect return value (facebook#14069)

    Mostly to catch this:
    
    ```js
    useEffect(async () => {
      // ...
      return cleanup;
    });
    ```
    
    Is this too restrictive? Not sure if you would want to do like
    
    ```js
    useEffect(() => ref.current.style.color = 'red');
    ```
    
    which would give a false positive here. We can always relax it to only warn on Promises if people complain.
    sophiebits committed Nov 2, 2018
    Configuration menu
    Copy the full SHA
    293fed8 View commit details
    Browse the repository at this point in the history
  5. chore(tests): don't rely on jest fake timers scheduling real timers (f…

    …acebook#14003)
    
    * chore: don't rely on jest fake timers scheduling real timers
    
    * re-add one part not working with Jest 23
    SimenB authored and nhunzaker committed Nov 2, 2018
    Configuration menu
    Copy the full SHA
    8eca0ef View commit details
    Browse the repository at this point in the history

Commits on Nov 5, 2018

  1. Bugfix: Add back early return in setOffsets which was removed between…

    … 16.4.2 and 16.5.0. Fails in Edge in some scenarios. (facebook#14095)
    einarq authored and gaearon committed Nov 5, 2018
    Configuration menu
    Copy the full SHA
    6c404d8 View commit details
    Browse the repository at this point in the history
  2. react-reconciler: Update README.md (facebook#13953)

    Replaced 'var' with 'const'
    marcelometal authored and gaearon committed Nov 5, 2018
    Configuration menu
    Copy the full SHA
    d34d1c3 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    ce90ffd View commit details
    Browse the repository at this point in the history
  4. fix(react-dom): Fix crash during server render (facebook#14103)

    Check for existence of `setTimeout` and `clearTimeout` in the runtime
    before using them, to ensure runtimes without them (like .NET ClearScript)
    do not crash just by importing `react-dom`.
    tnunes authored and gaearon committed Nov 5, 2018
    Configuration menu
    Copy the full SHA
    b305c4e View commit details
    Browse the repository at this point in the history
  5. Add Debug Tools Package for Introspection of Hooks (facebook#14085)

    * Add debug tools package
    
    * Add basic implementation
    
    * Implement inspection of the current state of hooks using the fiber tree
    
    * Support useContext hooks inspection by backtracking from the Fiber
    
    I'm not sure this is safe because the return fibers may not be current
    but close enough and it's fast.
    
    We use this to set up the current values of the providers.
    
    * rm copypasta
    
    * Use lastIndexOf
    
    Just in case. I don't know of any scenario where this can happen.
    
    * Support ForwardRef
    
    * Add test for memo and custom hooks
    
    * Support defaultProps resolution
    sebmarkbage committed Nov 5, 2018
    Configuration menu
    Copy the full SHA
    fd1256a View commit details
    Browse the repository at this point in the history
  6. Use Function.prototype.apply in warningWithoutStack (facebook#14107)

    console.error.apply() fails in IE9, but I verified this works (and it works everywhere else too). :)
    sophiebits committed Nov 5, 2018
    Configuration menu
    Copy the full SHA
    da04058 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    8b87ebf View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    ebdb47d View commit details
    Browse the repository at this point in the history
  9. Implement {,un}hideInstance on RN renderer (facebook#14115)

    This is required to use lazy.
    
    Test Plan:
    * Verified lazy works on a real world use case (shows spinner, shows real content).
    * Verified that if I change the primary content's styles to have `display: 'none'` then it never appears (i.e., the code in `unhide` reads the styles successfully)
    sophiebits committed Nov 5, 2018
    Configuration menu
    Copy the full SHA
    9d47143 View commit details
    Browse the repository at this point in the history

Commits on Nov 6, 2018

  1. [suspense] Avoid double commit by re-rendering immediately and reusin…

    …g primary children (facebook#14083)
    
    * Avoid double commit by re-rendering immediately and reusing children
    
    To support Suspense outside of concurrent mode, any component that
    starts rendering must commit synchronously without being interrupted.
    This means normal path, where we unwind the stack and try again from the
    nearest Suspense boundary, won't work.
    
    We used to have a special case where we commit the suspended tree in an
    incomplete state. Then, in a subsequent commit, we re-render using the
    fallback.
    
    The first part — committing an incomplete tree — hasn't changed with
    this PR. But I've changed the second part — now we render the fallback
    children immediately, within the same commit.
    
    * Add a failing test for remounting fallback in sync mode
    
    * Add failing test for stuck Suspense fallback
    
    * Toggle visibility of Suspense children in mutation phase, not layout
    
    If parent reads visibility of children in a lifecycle, they should have
    already updated.
    acdlite committed Nov 6, 2018
    Configuration menu
    Copy the full SHA
    e9a2ec9 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    600651e View commit details
    Browse the repository at this point in the history
  3. Enable hooks in www build (facebook#14116)

    The `enableHooks` feature flag used to only control whether the API
    was exposed on the React package. But now it also determines if the
    dispatcher and implementation are included in the bundle.
    
    We're using hooks in www, so I've switched the feature flag to `true`
    in the www build.
    
    (Alternatively, we could have two feature flags: one for the
    implementation and dispatcher, and one for exposing the API on the
    React package.)
    acdlite committed Nov 6, 2018
    Configuration menu
    Copy the full SHA
    0a0f503 View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    affb2b5 View commit details
    Browse the repository at this point in the history
  5. Fix unhiding in IE11 (facebook#14126)

    Setting to null isn't correct; setting to '' is. I opted to use dangerousStyleValue for consistency with the main path that we set things.
    
    Fixes facebook#14114.
    
    Test Plan:
    Verified setting to '' works in Chrome and IE11. (Setting to null works in Chrome but not in IE11.)
    sophiebits committed Nov 6, 2018
    Configuration menu
    Copy the full SHA
    e451299 View commit details
    Browse the repository at this point in the history
  6. Fix lazy() with defaultProps (facebook#14112)

    * Resolve defaultProps for Lazy components
    
    * Make test fail again
    
    * Undo the partial fix
    
    * Make test output more compact
    
    * Add a separate failing test for sync mode
    
    * Clean up tests
    
    * Add another update to both tests
    
    * Resolve props for commit phase lifecycles
    
    * Resolve prevProps for begin phase lifecycles
    
    * Resolve prevProps for pre-commit lifecycles
    
    * Only resolve props if element type differs
    
    * Fix Flow
    
    * Don't set instance.props/state during commit phase
    
    This is an optimization. I'm not sure it's entirely safe. It's probably worth running internal tests and see if we can ever trigger a case where they're different.
    
    This can mess with resuming.
    
    * Keep setting instance.props/state before unmounting
    
    This reverts part of the previous commit. It broke a test that verifies we use current props in componentWillUnmount if the fiber unmounts due to an error.
    gaearon committed Nov 6, 2018
    Configuration menu
    Copy the full SHA
    f777d19 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    b67c1a2 View commit details
    Browse the repository at this point in the history
  8. Check correct commit phase props in fuzz tester (facebook#14129)

    Adds a check to the existing fuzz tester to confirm that the props are
    set to the latest values in the commit phase. Only checks
    componentDidUpdate; we already have unit tests for the other lifecycles,
    so I think this is good enough. This is only a redundancy.
    acdlite committed Nov 6, 2018
    Configuration menu
    Copy the full SHA
    b020fb1 View commit details
    Browse the repository at this point in the history
  9. Recover from errors with a boundary in completion phase (facebook#14104)

    * Recover from errors with a boundary in completion phase
    
    * Use a separate field for completing unit of work
    
    * Use a simpler fix with one boolean
    
    * Reoder conditions
    
    * Clarify which paths are DEV-only
    
    * Move duplicated line out
    
    * Make it clearer this code is DEV-only
    gaearon committed Nov 6, 2018
    Configuration menu
    Copy the full SHA
    3c69a18 View commit details
    Browse the repository at this point in the history

Commits on Nov 7, 2018

  1. Configuration menu
    Copy the full SHA
    b4608dd View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    2aecbcd View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    8f2c89e View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    bd5a6d3 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    fd4527d View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    b50e63e View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    a24d510 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    ba19844 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    ff29de4 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    e3a7b96 View commit details
    Browse the repository at this point in the history
  11. Show deprecated context object warnings usage in ReactDOM server (fac…

    …ebook#14033)
    
    * Applies context object warnings to ReactDOM server
    trueadm committed Nov 7, 2018
    Configuration menu
    Copy the full SHA
    aa1ffe4 View commit details
    Browse the repository at this point in the history
  12. [Synchronous Suspense] Reuse deletions from primary tree (facebook#14133

    )
    
    Fixes a bug where deletion effects in the primary tree were dropped
    before entering the second render pass.
    
    Because we no longer reset the effect list after the first render pass,
    I've also moved the deletion of the fallback children to the complete
    phase, after the tree successfully renders without suspending.
    
    Will need to revisit this heuristic when we implement resuming.
    acdlite committed Nov 7, 2018
    Configuration menu
    Copy the full SHA
    e27720d View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    be63473 View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    5afa1c4 View commit details
    Browse the repository at this point in the history
  15. Invalid actualDuration+treeBaseDuration for hidden+suspended trees (f…

    …acebook#14065)
    
    * Fixed `treeBaseDuration` by propagating its value from the suspended tree to the Fragment React temporarily wraps around it when showing the fallback UI.
    * Fixed `actualDuration` by recording elapsed profiler time in the event of an error.
    * Fixed `actualDuration` in concurrent mode by propagating the time spent rendering the suspending component to its parent.
    
    Also updated ReactSuspensePlaceholder-test.internal to cover these new cases.
    bvaughn committed Nov 7, 2018
    Configuration menu
    Copy the full SHA
    3ff2c7c View commit details
    Browse the repository at this point in the history

Commits on Nov 8, 2018

  1. Use Entry in yarn build ... Instead of Label (facebook#14148)

    * Parse build script type and package names
    
    This ensures that `yarn build core dom` includes DOM.
    
    It also ensures that spaces like `yarn build "core, dom"` doesn't build EVERYTHING.
    
    * Get rid of label in bundles config
    
    Instead we just use the name from entry using fuzzy search.
    
    There is one special case. If you put in `/index` or `/index.js`.
    
    That allows to build things like `react/index` to only build isomorphic
    where as `react` would build everything. Or `react-dom/index` to exclude
    the server renderers.
    
    * Instead of matching `/index.js` just append it to the search string
    
    That way things like `yarn build react/` works too.
    sebmarkbage committed Nov 8, 2018
    Configuration menu
    Copy the full SHA
    051272f View commit details
    Browse the repository at this point in the history
  2. Refactor ESLint configuration to enable better IDE integration (faceb…

    …ook#13914)
    
    * Refactor ESLint configuration to enable better IDE integration
    
    * Minor tweaks
    NMinhNguyen authored and gaearon committed Nov 8, 2018
    Configuration menu
    Copy the full SHA
    3d8bda7 View commit details
    Browse the repository at this point in the history
  3. Adding logger pri (facebook#14155)

    n8schloss authored and acdlite committed Nov 8, 2018
    Configuration menu
    Copy the full SHA
    7c56013 View commit details
    Browse the repository at this point in the history
  4. [Synchronous Suspense] Don't delete children of suspended component (f…

    …acebook#14157)
    
    Vestigial behavior that should have been removed in facebook#13823.
    
    Found using the Suspense fuzz tester in facebook#14147.
    acdlite committed Nov 8, 2018
    Configuration menu
    Copy the full SHA
    f9e9913 View commit details
    Browse the repository at this point in the history

Commits on Nov 9, 2018

  1. Don't warn if an unmounted component is pinged (facebook#14158)

    * Add failing test for ping on unmounted component
    
    We had a test for this, but not outside of concurrent mode :)
    
    * Don't warn if an unmounted component is pinged
    acdlite committed Nov 9, 2018
    Configuration menu
    Copy the full SHA
    7fd1661 View commit details
    Browse the repository at this point in the history
  2. Suspense fuzz tester (facebook#14147)

    * Don't warn if an unmounted component is pinged
    
    * Suspense fuzz tester
    
    The fuzzer works by generating a random tree of React elements. The tree
    two types of custom components:
    
    - A Text component suspends rendering on initial mount for a fuzzy
      duration of time. It may update a fuzzy number of times; each update
      supsends for a fuzzy duration of time.
    - A Container component wraps some children. It may remount its children
      a fuzzy number of times, by updating its key.
    
    The tree may also include nested Suspense components.
    
    After this tree is generated, the tester sets a flag to temporarily
    disable Text components from suspending. The tree is rendered
    synchronously. The output of this render is the expected output.
    
    Then the tester flips the flag back to enable suspending. It renders the
    tree again. This time the Text components will suspend for the amount of
    time configured by the props. The tester waits until everything has
    resolved. The resolved output is then compared to the expected output
    generated in the previous step.
    
    Finally, we render once more, but this time in concurrent mode. Once
    again, the resolved output is compared to the expected output.
    
    I tested by commenting out various parts of the Suspense implementation
    to see if broke in the expected way. I also confirmed that it would have
    caught facebook#14133, a recent bug related to deletions.
    
    * When a generated test case fails, log its input
    
    * Moar fuzziness
    
    Adds more fuzziness to the generated tests. Specifcally, introduces
    nested Suspense cases, where the fallback of a Suspense component
    also suspends.
    
    This flushed out a bug (yay!) whose test case I've hard coded.
    
    * Use seeded random number generator
    
    So if there's a failure, we can bisect.
    acdlite committed Nov 9, 2018
    Configuration menu
    Copy the full SHA
    e58ecda View commit details
    Browse the repository at this point in the history
  3. Remove errant return assignment (facebook#14164)

    Oopsie!
    
    This could have been avoided if our types were modeled correctly with
    Flow (using a disjoint union).
    
    Fuzz tester didn't catch it because it does not generate cases where
    a Suspense component mounts with no children. I'll update it.
    acdlite committed Nov 9, 2018
    Configuration menu
    Copy the full SHA
    4b163fe View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    02e4848 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    c174f85 View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    9fb9199 View commit details
    Browse the repository at this point in the history
  7. Fix comment typo (facebook#14156)

    bgord authored and sophiebits committed Nov 9, 2018
    Configuration menu
    Copy the full SHA
    5618da4 View commit details
    Browse the repository at this point in the history
  8. Fix typos (facebook#14124)

    NE-SmallTown authored and sophiebits committed Nov 9, 2018
    Configuration menu
    Copy the full SHA
    1034e26 View commit details
    Browse the repository at this point in the history
  9. Don't run danger on bad build (facebook#14143)

    sizebot comments can be confusing when not based on reality.
    
    If results.json doesn't exist, danger will fail. This is what we want.
    sophiebits committed Nov 9, 2018
    Configuration menu
    Copy the full SHA
    9cc631a View commit details
    Browse the repository at this point in the history
  10. ESlint -> ESLint

    acdlite committed Nov 9, 2018
    Configuration menu
    Copy the full SHA
    2dd4ba1 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    d5e1bf0 View commit details
    Browse the repository at this point in the history
  12. Warn about conflicting style values during updates (facebook#14181)

    This is one of the most insidious quirks of React DOM that people run into. Now we warn when we think an update is dangerous.
    
    We still allow rendering `{background, backgroundSize}` with unchanging values, for example. But once you remove either one or change `background` (without changing `backgroundSize` at the same time), that's bad news. So we warn.
    
    Fixes facebook#6348.
    sophiebits committed Nov 9, 2018
    Configuration menu
    Copy the full SHA
    8ae867e View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    1a6ab1e View commit details
    Browse the repository at this point in the history
  14. Use unique thread ID for each partial render to access Context (faceb…

    …ook#14182)
    
    * BUG: ReactPartialRenderer / New Context polutes mutable global state
    
    The new context API stores the provided values on the shared context instance. When used in a synchronous context, this is not an issue. However when used in an concurrent context this can cause a "push provider" from one react render to have an effect on an unrelated concurrent react render.
    
    I've encountered this bug in production when using renderToNodeStream, which asks ReactPartialRenderer for bytes up to a high water mark before yielding. If two Node Streams are created and read from in parallel, the state of one can polute the other.
    
    I wrote a failing test to illustrate the conditions under which this happens.
    
    I'm also concerned that the experimental concurrent/async React rendering on the client could suffer from the same issue.
    
    * Use unique thread ID for each partial render to access Context
    
    This first adds an allocator that keeps track of a unique ThreadID index
    for each currently executing partial renderer. IDs are not just growing
    but are reused as streams are destroyed.
    
    This ensures that IDs are kept nice and compact.
    
    This lets us use an "array" for each Context object to store the current
    values. The look up for these are fast because they're just looking up
    an offset in a tightly packed "array".
    
    I don't use an actual Array object to store the values. Instead, I rely
    on that VMs (notably V8) treat storage of numeric index property access
    as a separate "elements" allocation.
    
    This lets us avoid an extra indirection.
    
    However, we must ensure that these arrays are not holey to preserve this
    feature.
    
    To do that I store the _threadCount on each context (effectively it takes
    the place of the .length property on an array).
    
    This lets us first validate that the context has enough slots before we
    access the slot. If not, we fill in the slots with the default value.
    sebmarkbage committed Nov 9, 2018
    Configuration menu
    Copy the full SHA
    961eb65 View commit details
    Browse the repository at this point in the history

Commits on Nov 10, 2018

  1. fix typo

    sebmarkbage committed Nov 10, 2018
    Configuration menu
    Copy the full SHA
    f8bfd58 View commit details
    Browse the repository at this point in the history
  2. Simplify CSS shorthand property warning (facebook#14183)

    I figured out a simpler way to do facebook#14181. It does allocate some but I think that's OK. Time complexity might even be better since we avoid the nested loops the old one had.
    sophiebits committed Nov 10, 2018
    Configuration menu
    Copy the full SHA
    b98adb6 View commit details
    Browse the repository at this point in the history

Commits on Nov 12, 2018

  1. Update Readme (facebook#14176)

    Replace core with react, dom-client with react-dom
    mmarkelov authored and gaearon committed Nov 12, 2018
    Configuration menu
    Copy the full SHA
    d204747 View commit details
    Browse the repository at this point in the history

Commits on Nov 13, 2018

  1. Configuration menu
    Copy the full SHA
    f55795c View commit details
    Browse the repository at this point in the history
  2. Save CI-built node_modules as build artifacts (facebook#14205)

    * Store node_modules generated by CI script as an artifact
    * NPM pack artifacts before archiving
    bvaughn committed Nov 13, 2018
    Configuration menu
    Copy the full SHA
    85f5a81 View commit details
    Browse the repository at this point in the history
  3. Update error codes

    acdlite authored and gaearon committed Nov 13, 2018
    Configuration menu
    Copy the full SHA
    3cd89da View commit details
    Browse the repository at this point in the history
  4. Add 16.6.3 Changelog (facebook#14223)

    * Add 16.6.3 Changelog
    
    * Remove unreleased fix
    
    * Drop another unreleased fix
    gaearon committed Nov 13, 2018
    Configuration menu
    Copy the full SHA
    d7fd679 View commit details
    Browse the repository at this point in the history

Commits on Nov 14, 2018

  1. [scheduler] Post to MessageChannel instead of window (facebook#14234)

    Scheduler needs to schedule a task that fires after paint. To do this,
    it currently posts a message event to `window`. This happens on every
    frame until the queue is empty. An unfortunate consequence is that every
    other message event handler also gets called on every frame; even if
    they exit immediately, this adds up to significant per-frame overhead.
    
    Instead, we'll create a MessageChannel and post to that, with a
    fallback to the old behavior if MessageChannel does not exist.
    acdlite committed Nov 14, 2018
    Configuration menu
    Copy the full SHA
    5bce0ef View commit details
    Browse the repository at this point in the history
  2. [scheduler] Remove window.postMessage fallback

    Every browser we can about supports MessageChannel. The ones we don't
    care about will fallback to the setTimeout implementation.
    acdlite committed Nov 14, 2018
    Configuration menu
    Copy the full SHA
    8feeed1 View commit details
    Browse the repository at this point in the history
  3. Add a checkbox to fixtures UI to choose React production build (faceb…

    …ook#13786)
    
    * Add a checkbox to fixtures UI to choose React production build
    
    * Assign header__label class name to label directly, instead of using a separate span
    
    * center the production checkbox vertically
    poeschko authored and nhunzaker committed Nov 14, 2018
    Configuration menu
    Copy the full SHA
    5f06576 View commit details
    Browse the repository at this point in the history

Commits on Nov 15, 2018

  1. Wrap shorthand CSS property collision warning in feature flag (facebo…

    …ok#14245)
    
    Disables the recently introduced (facebook#14181) warning for shorthand
    CSS property collisions by wrapping in a feature flag. Let's hold off
    shipping this until at least the next minor.
    acdlite committed Nov 15, 2018
    Configuration menu
    Copy the full SHA
    21d5f7d View commit details
    Browse the repository at this point in the history

Commits on Nov 16, 2018

  1. Reduce scheduler serialization overhead (facebook#14249)

    In the process of switching to MessageChannel, it seems the postMessage call was modified to pass `"*"` (originally the target origin value from `window.postMessage`). This actually ends up triggering serialization, whereas passing `undefined` bypasses.
    
    To save some investigation, passing a Number like `0` still incurs serialization overhead - `undefined` has special behavior.
    developit authored and acdlite committed Nov 16, 2018
    Configuration menu
    Copy the full SHA
    a22fabc View commit details
    Browse the repository at this point in the history

Commits on Nov 19, 2018

  1. Clear memoizedState on unmount of fiber to avoid memory leak (faceboo…

    …k#14218)
    
    * Clear properties on unmount of fiber to ensure objects are not retained
    trueadm committed Nov 19, 2018
    Configuration menu
    Copy the full SHA
    9b2fb24 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    5926765 View commit details
    Browse the repository at this point in the history
  3. Clear fields on unmount of fiber to avoid memory leak (facebook#14276)

    * Clear fields on unmount of fiber to avoid memory leak
    trueadm committed Nov 19, 2018
    Configuration menu
    Copy the full SHA
    0e9cb3f View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    ccb14e2 View commit details
    Browse the repository at this point in the history
  5. Remove import * as pattern from the codebase (facebook#14282)

    Whenever we do this, Rollup needs to materialize this as an object.
    This causes it to also add the Babel compatibility property which is
    unnecessary bloat. However, since when we use these, we leak the object
    this often also deopts any compiler optimizations.
    
    If we really need an object we should export default an object.
    
    Currently there is an exception for DOMTopLevelEventTypes since
    listing out the imports is a PITA and it doesn't escape so it should
    get properly inlined. We should probably move to a different pattern
    to avoid this for consistency though.
    sebmarkbage committed Nov 19, 2018
    Configuration menu
    Copy the full SHA
    c954efa View commit details
    Browse the repository at this point in the history

Commits on Nov 20, 2018

  1. Configuration menu
    Copy the full SHA
    327cf0e View commit details
    Browse the repository at this point in the history
  2. Warn about reassigning this.props (facebook#14277)

    * Warn about reassigning this.props
    
    * Improve the warning
    
    * Don't show the spammy bug warning if we suspect it's a component bug
    gaearon committed Nov 20, 2018
    Configuration menu
    Copy the full SHA
    a9fdf8a View commit details
    Browse the repository at this point in the history

Commits on Nov 22, 2018

  1. fix spelling error: Here's -> Here (facebook#14307)

    "Here's" should be changed to "Here" in the given sentence.
    Isaiah Nields authored and gaearon committed Nov 22, 2018
    Configuration menu
    Copy the full SHA
    1da3108 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    dd8205c View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    dc0dd4b View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    14be29b View commit details
    Browse the repository at this point in the history
  5. Fix resolution of outer props with React.memo() (facebook#14312)

    * Add failing test for defaultProps between lazy() and memo()
    
    * Add another regression test for defaultProps resolution order
    
    * Resolve outer props for MemoComponent
    gaearon committed Nov 22, 2018
    Configuration menu
    Copy the full SHA
    0c7189d View commit details
    Browse the repository at this point in the history

Commits on Nov 23, 2018

  1. Configuration menu
    Copy the full SHA
    7475120 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    686f106 View commit details
    Browse the repository at this point in the history
  3. Add basic release script snapshot test (facebook#14280)

    Added regression test for release scripts
    bvaughn committed Nov 23, 2018
    Configuration menu
    Copy the full SHA
    ed4c4a5 View commit details
    Browse the repository at this point in the history

Commits on Nov 24, 2018

  1. update fixtures/packaging/README.md (facebook#14320)

    I had some confusion yesterday with this, figured this reads a little better.  Ran these steps locally to verify they work.
    Sunil Pai committed Nov 24, 2018
    Configuration menu
    Copy the full SHA
    a7f270c View commit details
    Browse the repository at this point in the history

Commits on Nov 26, 2018

  1. Add progress bars to longer running async release tasks (facebook#14322)

    * Add progress bars to longer running async release tasks
    * Updated to 0.2 progress estimator version
    bvaughn committed Nov 26, 2018
    Configuration menu
    Copy the full SHA
    409066a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    33f6f5e View commit details
    Browse the repository at this point in the history

Commits on Nov 27, 2018

  1. Fix regression: Errors not emitted in streams (facebook#14314)

    Regression introduced in facebook#14182 resulted in errors no longer being emitted on streams, breaking many consumers.
    
    Co-authored-by: Elliot Jalgard <elliot.j@live.se>
    2 people authored and gaearon committed Nov 27, 2018
    Configuration menu
    Copy the full SHA
    ee3ef3a View commit details
    Browse the repository at this point in the history
  2. Make useEffect(async) warning more verbose (facebook#14327)

    * Make useEffect(async) warning more verbose
    
    * Nit
    gaearon committed Nov 27, 2018
    Configuration menu
    Copy the full SHA
    f93f340 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    48f1e5b View commit details
    Browse the repository at this point in the history
  4. Remove useMutationEffect (facebook#14336)

    useMutationEffect has problems (namely, refs aren't attached at the time that it runs) and we're not positive it's necessary. useLayoutEffect runs at the same time as componentDidMount/Update so it's sufficient for all existing use cases; it can be used in any case that useEffect happens too late. Until we figure out what we want to do, let's delete it.
    sophiebits committed Nov 27, 2018
    Configuration menu
    Copy the full SHA
    c2a2d8a View commit details
    Browse the repository at this point in the history

Commits on Nov 28, 2018

  1. Configuration menu
    Copy the full SHA
    4f964f0 View commit details
    Browse the repository at this point in the history
  2. Release script auto-determine the latest Canary build if none specifi…

    …ed (facebook#14339)
    
    * Release script auto-determine the latest Canary build if none specified
    bvaughn committed Nov 28, 2018
    Configuration menu
    Copy the full SHA
    88ada98 View commit details
    Browse the repository at this point in the history

Commits on Nov 29, 2018

  1. Validate propTypes for lazy() and memo() and warn about invalid patte…

    …rns (facebook#14298)
    
    * Add a test for current defaultProps behavior in lazy
    
    * Add a warning against definining defaultProps on the outer wrapper
    
    * Warn about setting propTypes too
    
    * Remove redundant async
    
    * Validate propTypes for resolved lazy types
    
    Note this only works for elements created after resolving. So it's not ideal. But it provides the best stack trace for those cases.
    
    * Add a test for lazy(forwardRef()) propTypes check
    
    * Validate memo() inner propTypes and warn about shadowing
    
    * Add test verifying nested lazy is unsupported
    
    * Change error wording to remove "Promise elements"
    
    * Improve error message for nested lazy() and add tests
    
    * Validate propTypes for memo in the reconciler when necessary
    
    * Add comments for why we're calling checkPropTypes
    
    * Fix Flow and lint
    
    * Undo unintentional formatting changes
    
    * Remove unnecessary case (it is handled by function code path)
    
    * Add test coverage for memo(fn.defaultProps).propTypes
    
    * Test should be agnostic of where resolving happens
    
    That's an implementation detail and we might want to change it later. Let's keep it easy by making tests just check that validation happened, not at which stage.
    
    * Unify traversal logic in createElement
    
    This moves all type traversal into createElement. When lazy resolves, we call createElement once to re-check.
    
    * Match prod behavior for propTypes/defaultProps shims closer
    
    * Revert "Unify traversal logic in createElement"
    
    This reverts commit 2e77ca4.
    
    See facebook#14298 (comment)
    
    * Undo unnecessary change to getComponentName
    gaearon committed Nov 29, 2018
    Configuration menu
    Copy the full SHA
    d14ba87 View commit details
    Browse the repository at this point in the history

Commits on Nov 30, 2018

  1. Configuration menu
    Copy the full SHA
    16e1204 View commit details
    Browse the repository at this point in the history
  2. Fix bug in cloneHook (facebook#14364)

    * Fixes facebook#14360 and adds a test for mixed priority dispatches.
    
    It was broken because `cloneHook` assigned `memoizedState` instead of
    `baseState` from the original hook to `baseState` of the clone.
    
    * tweak comments
    ioss authored and gaearon committed Nov 30, 2018
    Configuration menu
    Copy the full SHA
    f1bf281 View commit details
    Browse the repository at this point in the history
  3. [Fizz] New Server Rendering Infra (facebook#14144)

    * [Fizz] Add Flow/Jest/Rollup build infra
    
    Add a new package for react-stream which allows for custom server renderer
    outputs. I picked the name because it's a reasonable name but also
    because the npm name is currently owned by a friend of the project.
    
    The react-dom build has its own inlined server renderer under the
    name `react-dom/fizz`.
    
    There is also a noop renderer to be used for testing. At some point
    we might add a public one to test-renderer but for now I don't want to have
    to think about public API design for the tests.
    
    * Add FormatConfig too
    
    We need to separate the format (DOM, React Native, etc) from the host
    running the server (Node, Browser, etc).
    
    * Basic wiring between Node, Noop and DOM configs
    
    The Node DOM API is pipeToNodeStream which accepts a writable stream.
    
    * Merge host and format config in dynamic react-stream entry point
    
    Simpler API this way but also avoids having to fork the wrapper config.
    
    Fixes noop builds.
    
    * Add setImmediate/Buffer globals to lint config
    
    Used by the server renderer
    
    * Properly include fizz.node.js
    
    Also use forwarding to it from fizz.js in builds so that tests covers
    this.
    
    * Make react-stream private since we're not ready to publish
    
    or even name it yet
    
    * Rename Renderer -> Streamer
    
    * Prefix react-dom/fizz with react-dom/unstable-fizz
    
    * Add Fizz Browser host config
    
    This lets Fizz render to WHATWG streams. E.g. for rendering in a
    Service Worker.
    
    I added react-dom/unstable-fizz.browser as the entry point for this.
    
    Since we now have two configurations of DOM. I had to add another
    inlinedHostConfigs configuration called `dom-browser`. The reconciler
    treats this configuration the same as `dom`. For stream it checks
    against the ReactFizzHostConfigBrowser instead of the Node one.
    
    * Add Fizz Browser Fixture
    
    This is for testing server rendering - on the client.
    
    * Lower version number to detach it from react-reconciler version
    sebmarkbage committed Nov 30, 2018
    Configuration menu
    Copy the full SHA
    1d25aa5 View commit details
    Browse the repository at this point in the history

Commits on Dec 1, 2018

  1. Fixed scheduler setTimeout fallback (facebook#14358)

    * Fixed scheduler setTimeout fallback
    * Moved unit-test-specific setTimeout code into a new NPM package, jest-mock-scheduler.
    bvaughn committed Dec 1, 2018
    Configuration menu
    Copy the full SHA
    52bea95 View commit details
    Browse the repository at this point in the history

Commits on Dec 2, 2018

  1. Configuration menu
    Copy the full SHA
    f00c275 View commit details
    Browse the repository at this point in the history
  2. Automated fixture tests (facebook#14370)

    * Renamed snapshot test from test.js to snapshot-test.js
    * Automate fixtures tests
    bvaughn committed Dec 2, 2018
    Configuration menu
    Copy the full SHA
    8482cbe View commit details
    Browse the repository at this point in the history

Commits on Dec 3, 2018

  1. Configuration menu
    Copy the full SHA
    e382b0b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7a48c90 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    6bf5e85 View commit details
    Browse the repository at this point in the history

Commits on Dec 4, 2018

  1. Configuration menu
    Copy the full SHA
    d987172 View commit details
    Browse the repository at this point in the history
  2. Tweaked wording for v8 "performance cliff" issue

    Brian Vaughn committed Dec 4, 2018
    Configuration menu
    Copy the full SHA
    1dc108e View commit details
    Browse the repository at this point in the history

Commits on Dec 5, 2018

  1. Enable hooks in fabric (facebook#14301)

    because hooks are awesome.
    sahrens authored and sebmarkbage committed Dec 5, 2018
    Configuration menu
    Copy the full SHA
    39489e7 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    98eb5ae View commit details
    Browse the repository at this point in the history

Commits on Dec 6, 2018

  1. Configuration menu
    Copy the full SHA
    5bb4ad7 View commit details
    Browse the repository at this point in the history
  2. Implement pauseExecution, continueExecution, dumpQueue for Scheduler (f…

    …acebook#14053)
    
    * Implement pauseExecution, continueExecution, dumpQueue
    
    * Expose firstCallbackNode. Fix tests. Revert results.json
    
    * Put scheduler pausing behind a feature flag
    mrkev authored and acdlite committed Dec 6, 2018
    Configuration menu
    Copy the full SHA
    8df4d59 View commit details
    Browse the repository at this point in the history

Commits on Dec 7, 2018

  1. Dangerfile exits early if build failed (facebook#14400)

    * Dangerfile exits early (without leaving an error comment) if build failed
    bvaughn committed Dec 7, 2018
    Configuration menu
    Copy the full SHA
    f64906f View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    ce43a8c View commit details
    Browse the repository at this point in the history

Commits on Dec 12, 2018

  1. Configuration menu
    Copy the full SHA
    947bddd View commit details
    Browse the repository at this point in the history
  2. Add support for Suspense & lazy() to the react-is package (facebook#1…

    …4423)
    
    * Add support for lazy & Suspense to react-is
    pleunv authored and bvaughn committed Dec 12, 2018
    Configuration menu
    Copy the full SHA
    a22880e View commit details
    Browse the repository at this point in the history

Commits on Dec 13, 2018

  1. Inject overrideProps() fn to DevTools (facebook#14427)

    * Inject overrideProps() fn to DevTools
    
    This function will enable editing props for function components, host nodes, and special types like memo and forwardRef.
    bvaughn committed Dec 13, 2018
    Configuration menu
    Copy the full SHA
    7325ebe View commit details
    Browse the repository at this point in the history
  2. Enable hooks by default for FB React Native renderer (facebook#14435)

    * Enable hooks by default for FB React Native renderer
    * Updated RN+FB feature flags to make some of the dynamic ones static
    bvaughn committed Dec 13, 2018
    Configuration menu
    Copy the full SHA
    2743fb7 View commit details
    Browse the repository at this point in the history

Commits on Dec 14, 2018

  1. Removed Fabric-specific feature flag files and updated Rollup to use …

    …the (non-Fabric) React Native flag files. (facebook#14437)
    bvaughn committed Dec 14, 2018
    Configuration menu
    Copy the full SHA
    535804f View commit details
    Browse the repository at this point in the history
  2. Memoize promise listeners to prevent exponential growth (facebook#14429)

    * Memoize promise listeners to prevent exponential growth
    
    Previously, React would attach a new listener every time a promise is
    thrown, regardless of whether the same listener was already attached
    during a previous render. Because React attempts to render every time
    a promise resolves, the number of listeners grows quickly.
    
    This was especially bad in synchronous mode because the renders that
    happen when the promise pings are not batched together. So if a single
    promise has multiple listeners for the same root, there will be multiple
    renders, which in turn results in more listeners being added to the
    remaining unresolved promises. This results in exponential growth in
    the number of listeners with respect to the number of IO-bound
    components in a single render.
    
    Fixes facebook#14220
    
    * Memoize on the root and Suspense fiber instead of on the promise
    
    * Add TODO to fix persistent mode tests
    acdlite committed Dec 14, 2018
    Configuration menu
    Copy the full SHA
    4a10721 View commit details
    Browse the repository at this point in the history

Commits on Dec 18, 2018

  1. Configuration menu
    Copy the full SHA
    8bfef0d View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    653bc58 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    1c5aa2f View commit details
    Browse the repository at this point in the history

Commits on Dec 20, 2018

  1. React v16.7.0

    acdlite committed Dec 20, 2018
    Configuration menu
    Copy the full SHA
    c695b23 View commit details
    Browse the repository at this point in the history
  2. Update CHANGELOG for 16.7

    acdlite committed Dec 20, 2018
    Configuration menu
    Copy the full SHA
    84b8647 View commit details
    Browse the repository at this point in the history
  3. Update ReactFiberScheduler.js (facebook#14477)

    Fixed typo
    CarlMungazi authored and aweary committed Dec 20, 2018
    Configuration menu
    Copy the full SHA
    659c139 View commit details
    Browse the repository at this point in the history

Commits on Dec 25, 2018

  1. Allow node 11 as devEngine (facebook#14450)

    Using node 11 throws incompatibility error. This fixes it. Only test I performed was to run `yarn build -- --type=RN_OSS` everything seemed ok.
    iljadaderko authored and gaearon committed Dec 25, 2018
    Configuration menu
    Copy the full SHA
    fef40c0 View commit details
    Browse the repository at this point in the history

Commits on Jan 2, 2019

  1. Update ReactUpdateQueue.js (facebook#14521)

    Fix comment typo
    CarlMungazi authored and gaearon committed Jan 2, 2019
    Configuration menu
    Copy the full SHA
    3494ee5 View commit details
    Browse the repository at this point in the history

Commits on Jan 7, 2019

  1. Simplify wording of key warning (facebook#14503)

    I don't think "array or iterator" is adding anything, and it may well be confusing, especially since this is one of the first and most common warnings that devs see.
    sophiebits committed Jan 7, 2019
    Configuration menu
    Copy the full SHA
    547e059 View commit details
    Browse the repository at this point in the history

Commits on Jan 8, 2019

  1. Separate Object.is polyfill (facebook#14334)

    * Separate_Object_Is_Polyfill
    mmarkelov authored and trueadm committed Jan 8, 2019
    Configuration menu
    Copy the full SHA
    a9b035b View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    19ef0ec View commit details
    Browse the repository at this point in the history

Commits on Jan 9, 2019

  1. Configuration menu
    Copy the full SHA
    ab03e3d View commit details
    Browse the repository at this point in the history

Commits on Jan 10, 2019

  1. Configuration menu
    Copy the full SHA
    b4ad8e9 View commit details
    Browse the repository at this point in the history
  2. react-debug-tools accepts currentDispatcher ref as param (facebook#14556

    )
    
    * react-debug-tools accepts currentDispatcher ref as param
    
    * ReactDebugHooks injected dispatcher ref is optional
    bvaughn committed Jan 10, 2019
    Configuration menu
    Copy the full SHA
    f290138 View commit details
    Browse the repository at this point in the history

Commits on Jan 12, 2019

  1. Fix typo (facebook#14576)

    CarlMungazi authored and aweary committed Jan 12, 2019
    Configuration menu
    Copy the full SHA
    0005d1e View commit details
    Browse the repository at this point in the history

Commits on Jan 14, 2019

  1. Configuration menu
    Copy the full SHA
    3e15b1c View commit details
    Browse the repository at this point in the history
  2. Support configurable labels for custom hooks (facebook#14559)

    * react-debug-tools accepts currentDispatcher ref as param
    
    * ReactDebugHooks injected dispatcher ref is optional
    
    * Support custom values for custom hooks
    
    * PR feedback:
    
    1. Renamed useDebugValueLabel hook to useDebugValue
    2. Wrapped useDebugValue internals in if-DEV so that it could be removed from production builds.
    
    * PR feedback:
    
    1. Fixed some minor typos
    2. Added inline comment explaining the purpose of  rollupDebugValues()
    3. Refactored rollupDebugValues() to use a for loop rather than filter()
    4. Improve check for useDebugValue hook to lessen the chance of a false positive
    5. Added optional formatter function param to useDebugValue
    
    * Nitpick renamed a method
    bvaughn committed Jan 14, 2019
    Configuration menu
    Copy the full SHA
    edb1f59 View commit details
    Browse the repository at this point in the history

Commits on Jan 15, 2019

  1. Avoid new Set([iterable]) for thenables (facebook#14592)

    Fixes facebook#14583
    
    Using `new Set([iterable])` does not work with IE11's non-compliant Set
    implementation. By avoiding this pattern we don't need to require a Set
    polyfill for IE11
    aweary authored and gaearon committed Jan 15, 2019
    Configuration menu
    Copy the full SHA
    0fc1547 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7ad9806 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    0ca628b View commit details
    Browse the repository at this point in the history
  4. Configuration menu
    Copy the full SHA
    153a0b5 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    4392e38 View commit details
    Browse the repository at this point in the history

Commits on Jan 16, 2019

  1. Added Flow type to keep hooks dispatchers in-sync (facebook#14599)

    * Added Flow type to keep hooks dispatchers in-sync
    bvaughn committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    7ab8a8e View commit details
    Browse the repository at this point in the history
  2. Add ESLint rule playground (facebook#14609)

    * Add ESLint rule playground
    
    * Update index.js
    
    * Update index.js
    gaearon committed Jan 16, 2019
    Configuration menu
    Copy the full SHA
    8a12009 View commit details
    Browse the repository at this point in the history

Commits on Jan 17, 2019

  1. Configuration menu
    Copy the full SHA
    f2d74d3 View commit details
    Browse the repository at this point in the history
  2. Fix ReactiveDependencies rule

    jamiebuilds authored and gaearon committed Jan 17, 2019
    Configuration menu
    Copy the full SHA
    41fec63 View commit details
    Browse the repository at this point in the history
  3. fix lint errors

    jamiebuilds authored and gaearon committed Jan 17, 2019
    Configuration menu
    Copy the full SHA
    f227df8 View commit details
    Browse the repository at this point in the history
  4. Support useLayoutEffect

    gaearon committed Jan 17, 2019
    Configuration menu
    Copy the full SHA
    5d5b180 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    816b8ae View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    e7f44f1 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    c1ab460 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    902cb08 View commit details
    Browse the repository at this point in the history
  9. Shorter rule name

    gaearon committed Jan 17, 2019
    Configuration menu
    Copy the full SHA
    8797fa6 View commit details
    Browse the repository at this point in the history