431 Commits

Author SHA1 Message Date
David East
21b6702f36 Merge pull request #254 from FirebaseExtended/de-register-version
Add version number as an export
2020-05-20 15:54:32 -06:00
David East
c69d03a4a9 Update reactfire/after.build.js
Co-authored-by: Jeff <jhuleatt@gmail.com>
2020-05-20 15:05:25 -06:00
David East
a1d2e3f6a4 Update reactfire/after.build.js
Co-authored-by: Jeff <jhuleatt@gmail.com>
2020-05-20 15:04:55 -06:00
Jeff Huleatt
40842f3fff fix build 2020-05-19 23:33:31 +00:00
Jeff Huleatt
7527c0d7bb update yarn lockfile 2020-05-19 23:33:22 +00:00
jhuleatt
e8581aa8c3 run yarn upgrade 2020-05-19 10:29:31 -07:00
David East
68cfc7957c Merge pull request #253 from FirebaseExtended/de-preload-updates
Update preload methods in sample
2020-05-06 20:12:09 -06:00
David East
07b867a764 Update reactfire/firebaseApp/index.tsx
Co-authored-by: Jeff <jhuleatt@gmail.com>
2020-05-06 20:10:21 -06:00
David East
dd7c27ae82 Add version number to the build 2020-05-04 15:17:31 -06:00
David East
b55017d55f Update preload methods in sample 2020-05-04 12:34:54 -06:00
allcontributors[bot]
b82b58a814 docs: add jhuleatt as a contributor (#242)
* docs: update README.md [skip ci]

* docs: update .all-contributorsrc [skip ci]

Co-authored-by: allcontributors[bot] <46447321+allcontributors[bot]@users.noreply.github.com>
Co-authored-by: Jeff <jhuleatt@gmail.com>
2020-04-17 10:17:10 -07:00
allcontributors[bot]
27e8338578 docs: add w3bdesign as a contributor (#246)
* docs: update README.md [skip ci]

* docs: update .all-contributorsrc [skip ci]

Co-authored-by: allcontributors[bot] <46447321+allcontributors[bot]@users.noreply.github.com>
Co-authored-by: Jeff <jhuleatt@gmail.com>
2020-04-17 10:15:25 -07:00
allcontributors[bot]
e225914086 docs: add prescottprue as a contributor (#247)
* docs: update README.md [skip ci]

* docs: update .all-contributorsrc [skip ci]

Co-authored-by: allcontributors[bot] <46447321+allcontributors[bot]@users.noreply.github.com>
2020-04-17 10:11:42 -07:00
Shelley Cincotta
2b6f8e882b Quickstart: Add SuspenseWithPerf import (#244)
* Update import step to add SuspenseWithPerf

* Added review comment: Use function component term

* Corrected import terminology
2020-04-02 11:21:29 -07:00
Shelley Cincotta
e32aa4083b Readme and Quickstart Docs Improvements (#239)
Rework quickstart + minor README update
2020-03-31 13:34:07 -07:00
Jeff
d4d4476471 implement all-contributors spec (#240)
https://allcontributors.org/docs/en/overview
2020-03-31 10:53:48 -07:00
Jeff
848eaa3c69 StorageImage use useStorage (#233) v2.0.3 2020-03-17 09:26:17 -07:00
dependabot[bot]
c305e3d478 Bump acorn from 5.7.3 to 5.7.4 (#231)
Bumps [acorn](https://github.com/acornjs/acorn) from 5.7.3 to 5.7.4.
- [Release notes](https://github.com/acornjs/acorn/releases)
- [Commits](https://github.com/acornjs/acorn/compare/5.7.3...5.7.4)

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2020-03-14 17:05:41 -07:00
James Daniels
80b9431ceb Don't build twice on CI and don't ignore the jest setup file v2.0.2 2020-03-11 14:59:35 -07:00
James Daniels
0de1068e81 Don't use JS SDK private APIs. (#224)
* Don't use JS SDK private APIs.
* Add note about polyfills
2020-03-11 12:12:06 -07:00
James Daniels
5487096955 Now that we're GA don't publish RCs on latest v2.0.1 2020-02-26 16:15:40 -08:00
Jeff
325415e7b0 Fix useObservable edge case (#220)
* changes caused by updated prettier config
* change "share()" to "shareReplay(1)"
v2.0.0 v2.0.0-rc.3
2020-02-26 14:51:47 -08:00
James Daniels
51baa2266f Update preloadFirestore example 2020-02-25 23:31:33 -08:00
James Daniels
8a54d42d9e New preload API & larger column width (#219) v2.0.0-rc.2 2020-02-25 23:19:56 -08:00
James Daniels
ce716feab1 Using our subject/cache to fix the init race I introduced (#218)
* Using our subject/cache to fix the init race I introduced with the refactor

* Naming

* Await init on non-contextual app, if one is passed

* void | Promise<any> better describes the contract

* Global cache and test
2020-02-25 15:47:33 -08:00
Jeff
32c2bb3c40 [WIP] Docs updates 📚 (#208)
* add sdk init to docs

* add profile page example

* add Analytics example

* address review comments

* update root description

* enable concurrent mode in initial sample

* update quickstart

* automatically fork on stackblitz

* fix readme sample

* remove contributing in favor of contributing.md

* move docs links higher up

* document useObservable and preloadFirestoreDoc

* update usage docs

* add useTransition docs

* fix anchor links

* polish

* fix useobservable link

* Address James and David's in-person feedback
2020-02-25 11:49:51 -08:00
jhuleatt
c67dfa7554 update deps 2020-02-24 09:32:28 -08:00
jhuleatt
6065d7ffaa remove extra folder 2020-02-24 09:32:20 -08:00
James Daniels
e6962e38e7 Remove perf import on README
No longer need to manually import `firebase/performance`
2020-02-20 14:11:56 -08:00
James Daniels
3cebaa921a Refactoring use/preload and more (#215)
* Drop `initPerformance` (closes #207)
* Cleaning up the use/preload types
* Use my good friend `Proxy` to allow access to both the `serviceProps` and the initialized instance without double calling (e.g, `useAuth()()`)
* More checks against double initializing
* Added binding to the initialize call (closes #213)
* `SuspenseWithPerf` now lazy loads performance monitoring and uses the user timing API
* Fixed the CJS build with a better external test (closes #214)
v2.0.0-rc.1
2020-02-20 13:32:37 -08:00
James Daniels
aa0f822417 Updating the FOSS & Github urls 2020-02-19 21:26:06 -08:00
James Daniels
d1068fe9d3 Remove next and canary tags from README and quickstart 2020-02-12 16:45:57 -08:00
James Daniels
64d26c04ad Bump the timeout on Cloud Build 2020-02-12 16:20:54 -08:00
James Daniels
66246ca7ab Fix worked kinda, sorta, still flaking. Comment out for now. v2.0.0-rc.0 2020-02-12 15:36:44 -08:00
James Daniels
11d6a1926d Fix for the flaky test 2020-02-12 15:26:00 -08:00
David Smith
ca32a93aea Add hooks to get firestore document data once (#211)
* Add hooks to get firestore document data once
* use checkStartWithValue for consistency

Co-authored-by: James Daniels <james@jamesdaniels.net>
2020-02-12 13:07:48 -08:00
James Daniels
121f5e15f9 Refactor on the core observable engine (#210)
Refactoring `useObservable` and `preloadObservable` to be more suspense friendly.

The core idea here is that our "observable" should expose a promise that resolves on first emission (which can be thrown for suspense), a synchronous means of getting the latest value (to pass into `useState`), and a shared subscription for use thereafter (for `useEffect`).

As a matter of optimization they will keep their cache around for only a present amount of time (30 seconds by default) unless they are subscribed to (`useEffect`); in which case the cache will remain until the component is unloaded. This should be enough time to prevent suspense from thrashing.

To encapsulate this behavior this we've implemented our own `Subject`.

Other changes in this PR:

* Ensure that the observable cache has to be keyed very specifically taking into account the firebase app, options, etc.
* Make sure no cache keys overlap on tests & different exports
* We're using more typescript in the tests, build them as part of the main build step since jest wasn't playing nice
* There's still some meh types kicking around here, should take as an AI
* Errors are thrown again until the cache timeout elapses, put down a TODO for now
* `FirebaseAppProvider` now throws if the provided config does not match the existing instance options, rather than simply returning the default
* `FirebaseAppProvider` now takes an `appName` property allowing you to have more than one app
2020-02-12 12:59:03 -08:00
David East
e2f1b1f58c Preload settings callbacks (#205)
Provide a way for all SDKs to be initialized before they're called by any ReactFire hooks
2020-01-31 11:02:28 -08:00
David East
f417133bd0 Remote Config API (#204)
Add Remote Config
2020-01-30 10:27:58 -08:00
Jeff
33f1e6ae78 Fix build: "sh: 1: node: Permission denied" (#199)
* add `--unsafe-perm` flag

* remove . so that .nvmrc file is used
2020-01-17 15:35:57 -08:00
Jeff
6fff36284e Update Dependencies (#200)
* update deps

* fix rollup import
2020-01-16 14:52:23 -08:00
Jeff
4b90236831 Add *Data methods for RTDB (#184)
* extract checkOptions and friends

* add useDatabaseListData and useDatabaseObjectData

* update sample

* update types

* add to docs
2020-01-16 13:56:25 -08:00
Jeff
fb1c51691b correct contributing file (#198) 2020-01-15 16:39:53 -08:00
Jeff
e1daab435f add missing packages (#191) 2019-12-09 16:00:09 -08:00
James Daniels
1fce6b94ac Make npm canary version less sensitive to NPM version & fix sh syntax 2019-11-18 16:57:02 -08:00
James Daniels
854b2d2ee2 Publish release candidates under the NPM latest tag 2019-11-18 16:46:01 -08:00
James Daniels
592457eabf Don't ignore the rollup.js 2019-11-18 16:21:08 -08:00
Jeff
14ea5295f1 Remove all references to sample-complex and sample-simple (#187)
* remove all references to sample-complex

* remove sample-simple too
2019-11-13 14:43:38 -08:00
Jeff
2c02415cf0 fix package.json (#186) 2019-11-12 17:31:40 -08:00
jhuleatt
7820b0f162 remove the sample-complex folder 2019-11-11 16:59:08 -08:00