Comments (12)
Wait, are you saying you fixed #46 then?
from nativescript-plugin-firebase.
No, we turned out attention to making the app work great on iOS :) - let me comment the other issue
from nativescript-plugin-firebase.
Once I figure out #46 for your app I'll take a look at this one. But it's a toughie.
from nativescript-plugin-firebase.
Just to note, the ordering is super nutty atm
from nativescript-plugin-firebase.
If I add a console.log
statement in the query function you linked to above then I won't see it in my log so I don't think the query is executed.
Instead, in the constructor
of the same class there's a firebase.addValueEventListener
which I think is the one actually retrieving the data here.
You could btw sort clientside to avoid using the query
function at all.
from nativescript-plugin-firebase.
the query is hit by the event listener when the data changes. So if you add an item, you should see that query run. It's also hit when the page first loads to retrieve the list, or any time the database data is altered. I would think that it would be more efficient for the plugin to handle the sorting on the database side, right? If it is too hard, though, we can work on client side sorting. 👍 thanks!
from nativescript-plugin-firebase.
Hey Jen, did you try adding that log statement? Seriously, I don't think the query runs at all so sorting is never applied.
from nativescript-plugin-firebase.
ooh, I think you're right. We have changed the code to make the sync work. Debugging now. Thanks for the heads up!
from nativescript-plugin-firebase.
It has to be sorted using a pipe if you want to done client side
from nativescript-plugin-firebase.
@jlooper I've also faced the same problem. Sorting in firebase.query especially with firebase.QueryLimitType.LAST
is a bit invalid. I'd to use a custom sort filter over the list again!
from nativescript-plugin-firebase.
I am unable to sort data using singleEvent: false
is that it expected behavior? The sorting works when I use singleEvent: true
from nativescript-plugin-firebase.
Issue #405 seems to be relevant here. I feel piping on the client side is a hacky work-around seeing as it'll be a major hit to performance on bigger queries.
from nativescript-plugin-firebase.
Related Issues (20)
- M1 Issue - FirebaseSDK HOT 4
- Several "session_start" event are created on iOS 15 HOT 1
- ERROR TypeError: firebase.init is not a function.
- AdMob error: TypeError: Cannot set property 'resolve' of undefined
- Class constructor ContentView cannot be invoked without 'new'
- Android App Not working with NS 8.2. HOT 42
- A problem occurred configuring root project 'firebase'.
- microsoft login
- Android 12 background notification led to crash (PendingIntent) HOT 6
- Unable to run new deployment HOT 1
- ion
- Error trying to install @nativescript/firebase
- barcode scanning issue - iPhone 13 Pro and iPhone 13 Pro max
- Cannot read property 'ads' of undefined on NativeScript 8.2.3 HOT 1
- Plugin with id 'com.google.gms.google-services' not found. HOT 13
- SetValue of type Date Error on iOS
- Barcode Scanning issue on native script 8 with native camera control
- Mark this repository as deprecated HOT 1
- Firebase Authentication functions are giving error "No reference found.
- Firebase Messaging crash issue in Android 13 HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nativescript-plugin-firebase.