kendalled / nuxt-fire

πŸ”₯ Easily integrate Firebase into your Nuxt 2 project. πŸ”₯

Home Page:https://nuxtfire.netlify.com/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

πŸ”₯ Nuxt-Fire

Downloads Version License

Easily integrate Firebase into your Nuxt 2 project.

πŸ“– Read Full Documentation

Quick Setup

Install Nuxt-Fire via NPM or Yarn:

yarn add nuxt-fire # OR npm i nuxt-fire

Quick Config

Add the following to your nuxt.config.js.

See all configuration options here.

modules: [
    [
      'nuxt-fire',
      {
        config: {
          apiKey: '<apiKey>',
          authDomain: '<authDomain>',
          databaseURL: '<databaseURL>',
          projectId: '<projectId>',
          storageBucket: '<storageBucket>',
          messagingSenderId: '<messagingSenderId>',
          appId: '<appId>',
          measurementId: '<measurementId>'
        },
        services: {
          auth: true // Just as example. Can be any other service.
        }
      }
    ]
  ],

Quick Usage

Now you can use all Firebase services with $this.Auth, this.$fireStore, this.$fireMess etc. (see list here).

Example:

try {
  await this.$fireAuth.createUserWithEmailAndPassword('foo@foo.foo', 'test')
} catch (e) {
  handleError(e)
}

Advanced Setup

There is much more options to this simple setup, check out our full documentation below:

πŸ“– Read Documentation

License

MIT - 2018-present Pascal Luther

About

πŸ”₯ Easily integrate Firebase into your Nuxt 2 project. πŸ”₯

https://nuxtfire.netlify.com/

License:MIT License


Languages

Language:JavaScript 100.0%