Need help with firebase-module?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

nuxt-community
501 Stars 69 Forks MIT License 936 Commits 18 Opened issues

Description

🔥 Easily integrate Firebase into your Nuxt project. 🔥

Services available

!
?

Need anything else?

Contributors list

nuxt-firebase logo

Easily integrate Firebase into your Nuxt project.

IMPORTANT!

:warning: BREAKING CHANGES IN VERSION 7.0.0!:
Version 7 brings major breaking changes. Make sure to carefully read through the migration guide when migrate your application. See the release notes here.

Links

Quick Setup

Make sure you are using the newest version of Nuxt and have Firebase >8.0.0 installed in your project.

yarn add firebase # OR npm i firebase

Install the module via NPM or Yarn:

yarn add @nuxtjs/firebase # OR npm i @nuxtjs/firebase

Quick Config

Add the following to your nuxt.config.js.

See all configuration options here.

modules: [
    [
      '@nuxtjs/firebase',
      {
        config: {
          apiKey: '',
          authDomain: '',
          projectId: '',
          storageBucket: '',
          messagingSenderId: '',
          appId: '',
          measurementId: ''
        },
        services: {
          auth: true // Just as example. Can be any other service.
        }
      }
    ]
  ],

Quick Usage

Now you can use all Firebase services with

this.$fire.auth
,
this.$fire.firestore
,
this.$fire.messaging
etc. (see list here).

Example:

try {
  await this.$fire.auth.createUserWithEmailAndPassword('[email protected]', 'test')
} catch (e) {
  handleError(e)
}

Issues, questions & requests

If you have any questions or issues, check out the Nuxt Discord server.

License

MIT - Nuxt-Community - Pascal Luther

We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.