Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/FirebaseExtended/polymerfire
Polymer Web Components for Firebase
https://github.com/FirebaseExtended/polymerfire
Last synced: 3 months ago
JSON representation
Polymer Web Components for Firebase
- Host: GitHub
- URL: https://github.com/FirebaseExtended/polymerfire
- Owner: FirebaseExtended
- License: mit
- Created: 2016-05-18T17:09:40.000Z (over 8 years ago)
- Default Branch: master
- Last Pushed: 2020-08-10T13:47:01.000Z (about 4 years ago)
- Last Synced: 2024-04-23T20:18:23.055Z (7 months ago)
- Language: HTML
- Homepage: https://www.webcomponents.org/element/firebase/polymerfire
- Size: 310 KB
- Stars: 460
- Watchers: 67
- Forks: 153
- Open Issues: 112
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
Awesome Lists containing this project
- awesome-firebase - PolymerFire - The officially supported Polymer bindings for the Firebase platform. (Adapters)
- awesome-firebase - PolymerFire - 파이어 베이스를 위한 Polymer 웹 컴포넌트입니다. (웹)
README
[![Build status](https://travis-ci.org/firebase/polymerfire.svg?branch=master)](https://travis-ci.org/firebase/polymerfire)
## Status
![Status: Archived](https://img.shields.io/badge/Status-Archived-red)
This library is no longer actively maintained. We **do not recommend** using this library in production.
If you maintain a fork of this library that you believe is healthier than the official version, we may consider recommending your fork. Please open a Pull Request if you believe that is the case.
## <firebase-app>
The firebase-app element is used for initializing and configuring your
connection to firebase.## <firebase-auth>
`firebase-auth` is a wrapper around the Firebase authentication API. It notifies
successful authentication, provides user information, and handles different
types of authentication including anonymous, email / password, and several OAuth
workflows.Example Usage:
```html
```
The `firebase-app` element initializes `app` in `firebase-auth` (see
`firebase-app` documentation for more information), but an app name can simply
be specified at `firebase-auth`'s `app-name` property instead.JavaScript sign-in calls can then be made to the `firebase-auth` object to
attempt authentication, e.g.:```javascript
this.$.auth.signInWithPopup()
.then(function(response) {// successful authentication response here})
.catch(function(error) {// unsuccessful authentication response here});
```This popup sign-in will then attempt to sign in using Google as an OAuth
provider since there was no provider argument specified and since `"google"` was
defined as the default provider.## <firebase-document>
The firebase-document element is an easy way to interact with a firebase
location as an object and expose it to the Polymer databinding system.For example:
```html
```
This fetches the `noteData` object from the firebase location at
`/users/${userId}/notes/${noteId}` and exposes it to the Polymer
databinding system. Changes to `noteData` will likewise be, sent back up
and stored.`` needs some information about how to talk to Firebase.
Set this configuration by adding a `` element anywhere in your
app.## <firebase-query>
`firebase-query` combines the given properties into query options that generate
a query, a request for a filtered, ordered, immutable set of Firebase data. The
results of this Firebase query are then synchronized into the `data` parameter.Example usage:
```html
Polymer({
properties: {
uid: String,
data: {
type: Object,
observer: 'dataChanged'
}
},dataChanged: function (newData, oldData) {
// do something when the query returns values
}
});```