-
Notifications
You must be signed in to change notification settings - Fork 164
Expose useTracker hook and reimplement withTracker HOC on top of it #262
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
Closed
Closed
Changes from all commits
Commits
Show all changes
28 commits
Select commit
Hold shift + click to select a range
f9c6ae3
Expose useTracker hook and reimplement withTracker HOC on top of it
yched eecab69
run the callback non-reactively in the initial render
yched 46c243a
no need for useCallback
yched a2cc120
setup computation once on mount, deferring subscriptions until didMount
yched b61f809
stop deferred inital subscriptions on computation invalidate rather t…
yched 2589ac7
Revert last two commits: no reactivity on mount
yched c8c1c5f
comments
yched 24be369
minor: code style
yched e509e26
minor: coding style
yched 5d25bf2
Handle Mongo.Cursor warnings checks inside useTracker, and user React…
yched ae3f323
Add a note about refs BC break and #262
yched 3caa109
bump React minimum version to 16.8
yched 61ef31e
minor: streamline comments
yched 65e619d
minor: streamline useEffect
yched 3841a4c
minor: streamline client / server versions of useTracker
yched ef64751
default useTracker's deps param to [] to avoid infinte rerender loop …
yched 4486531
Docs
yched 0041ce7
minor: linebreak fix
yched 92f8576
docs : unify headers for useTracker / withTracker sections (include a…
yched d8922dd
docs : typos
yched c4e24f2
remove createContainer / ReactMeteorData
yched b7a92d6
docs : added compatibility notes
yched c135ef0
docs : adjust formatting / fix unfinished sentence / link to React li…
yched e79b596
docs : better doc for the react-hooks/exhaustive-deps ESLint config
yched 17322a5
remove dependency on tmeasday:check-npm-versions
yched f0a0328
optim : only warn about Mongo.Cursor in dev environment
yched eb55a16
forward references to the inner component (supercedes #266)
yched 514a87d
fix checkCursor() when reactiveFn returns null
yched File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
import React from 'react'; | ||
|
||
if (Meteor.isDevelopment) { | ||
const v = React.version.split('.'); | ||
if (v[0] < 16 || v[1] < 8) { | ||
console.warn('react-meteor-data 2.x requires React version >= 16.8.'); | ||
} | ||
} | ||
|
||
export { default as withTracker } from './withTracker.jsx'; | ||
export { default as useTracker } from './useTracker.js'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.