dillon1000/react

Commit

Dedup conditional in ReactScheduler (#12680)

**what is the change?:**
We had a condition to set either 'performance.now' or 'Date.now' as the
'now' function.

Then later we had another conditional checking again if
'performance.now' was supported, and using it if so, otherwise falling
back to 'Date.now'.

More efficient to just use the 'now' shortcut defined above.

**why make this change?:**
Fewer lines, clearer code.

**test plan:**
Now that we have tests we can run them :)
Browse files
Changed paths1 file
First-parent comparison
M packages/react-scheduler/src/ReactScheduler.js Modified
Patch

Files changed

Rendering syntax-highlighted changes…