polymerfire

Polymer 1.x + Firebase 2.x: How to push or put data to Firebase using Polymerfire?

会有一股神秘感。 提交于 2020-02-24 11:33:04
问题 Using Polymerfire, I want to add new nodes to a Firebase without overwriting data. (I call this push or put behavior.) In other words. I want to start with this: State A my-app | - emails | + email1@example,com + email2@example,com And finish with this. State B my-app | - emails | + email1@example,com + email2@example,com + email3@example,com + email4@example,com But when I start with State A and do this: <firebase-document id="doc" app-name="app" data="{{data}}"> </firebase-document> ...

polymerfire-auth error “auth/popup-closed-by-user” 404 on popup redirect

房东的猫 提交于 2020-01-05 07:30:32
问题 I created a Firebase project based on Polymer Starter Kit and made some modifications to fix routing, but the sign-in popup immediately closes and logs an error: The popup has been closed by the user before finalizing the operation. The _authenticate function (in the code below) is called to authenticate the user. I was able to properly set it up both on Facebook and Google console, so I'm not sure what the error means. Here's my code: <dom-module id="my-app"> <template> !-- Firebase Setup --

Polymer 1 and Firebase: How to deal with a large dataset with dom-repeat?

一曲冷凌霜 提交于 2019-12-25 02:47:16
问题 So, I am using firebase-query to read a dataset of about 9000 items. Then I am displaying the list of items with dom-repeat (with all sorts of filtering and sorting options). It all worked well when I tested it with 10 items or so, but now that I am reading the full dataset I have no idea how to manage it... the entire 9000 items are displayed, which obviously is not quite manageable. Here is a simplified version of what I have: <firebase-query path="/organisations" data="{{organisations}}"><

How to insert data into Firebase using Polymerfire (mutiple nodes + multiple paths)

戏子无情 提交于 2019-12-19 04:22:53
问题 My use case is that I have an <iron-form> with a single <paper-textarea> field that accepts a string list of email addresses which I parse into an array, then I want to: Store the individual email addresses in my Firebase (for indexing and lookup purposes), at multiple locations (per data fan out technique), with a single write operation (because I don't want to make 100 API calls if the list is that long) and without overwriting any existing data. Specifically, I want to start with State A,

How to insert data into Firebase using Polymerfire (mutiple nodes + multiple paths)

▼魔方 西西 提交于 2019-12-19 04:22:26
问题 My use case is that I have an <iron-form> with a single <paper-textarea> field that accepts a string list of email addresses which I parse into an array, then I want to: Store the individual email addresses in my Firebase (for indexing and lookup purposes), at multiple locations (per data fan out technique), with a single write operation (because I don't want to make 100 API calls if the list is that long) and without overwriting any existing data. Specifically, I want to start with State A,

Polymer + Firebase (Polymerfire): <firebase-query> not working inside single page app view (with <firebase-app> located in my-app.html)

此生再无相见时 提交于 2019-12-18 04:28:05
问题 I'm trying to push data to Firebase using Polymerfire and the Polymer App Toolbox template: my-app.html contains a configured <firebase-app> component. my-models.html (which is a page configured in my-app.html routes) contains a <add-model> component <add-model> is a form with a <firebase-query> , <firebase-auth> , input, and submit button. I attempt to push data using <firebase-query> with the following function in the add-model.html Polymer object: Polymer({ is: 'add-model', properties: {

Polymerfire google auth not working

落花浮王杯 提交于 2019-12-11 05:51:34
问题 I'm new to Polymer and Firebase (and as a programmer as well), I'm trying to do a simple login with Google and show the user is logged in. Google Auth is enabled in Firebase. The logout button should be hidden when there is no user logged in, but when I click the login button, nothing happens. There are no warnings in the browser's console. Here is the code that I'm using: <!DOCTYPE html> <html> <head> <link rel="import" href="bower_components/polymerfire/firebase-app.html"> <link rel="import

Data binding to a dynamic path in Polymer

自作多情 提交于 2019-12-11 01:57:19
问题 I am building a web app with Polymer 1.0 and Firebase, and I want to have the view change when data was entered into a path with a user ID in the path. To do that, I want to do something like this: [[question.answers.(user.uid).choice]] Let me explain in more detail. So, in the template, I have something like this: <ul id="question-list"> <template is="dom-repeat" items="[[questions]]" sort="_computeSort" as="question"> <li class="card question" data-key="[[question.$key]]" question="[

Use Firebase-query to get data from an array of ID's

[亡魂溺海] 提交于 2019-12-10 12:18:36
问题 I'm trying to use Polymerfire's firebase-query to retrieve a list of children for each ID in an array. I have and array with three ID's and a firebase-query that looks like: <firebase-query id="teamContacts" path= "{{teamConPath}}" data="{{teamConData}}"></firebase-query> and a couple observers that look like: teamConData: { observer: '_teamConDataChanged' }, teamConPath: { value: '', observer: '_teamConPathChanged' }, _teamConPathChanged: function(newValue, oldValue) { var self = this; if (

Polymerfire dom-repeat with Firebase objects

社会主义新天地 提交于 2019-12-08 06:42:29
问题 I want to be able to show a list of all the FirstName and ZipCodes . My data looks as follows: /user | |__INAxzxWKQrSAfA7tapV0c08YvfJ3 | |____FirstName:"James" | |____ZipCode:"90210" | |__ANAczxWKQrEAfA7tapV0c08YvfX6 |____FirstName:"Simon" |____ZipCode:"40213" and Polymerfire's firebase document looks like this <firebase-document app-name="contacts" path="/user" data="{{allUsers}}"> </firebase-document> And my dom repeat is like <template is="dom-repeat" items="{{_makeArray(allUsers)}}"> <div