# firebase-auth-functions

> This package contains pre-built firebase cloud functions and is intended to be used in conjuction with [react-redux-firebase-auth](https://www.npmjs.com/package/react-redux-firebase-auth)

Latest version **1.0.2** (published 2021-12-25) · MIT license · 0 weekly downloads

## Install

```sh
npm install firebase-auth-functions
pnpm add firebase-auth-functions
yarn add firebase-auth-functions
bun add firebase-auth-functions
```

## Health

**Score 30/100 (F)** — status: abandoned.

Positive: has types; esm support; no vulnerabilities; high quality score.

Warnings: low downloads.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.2 |
| Published | 2021-12-25 |
| First published | 2021-10-30 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | ESM + CommonJS |
| Node | >=10 |
| Dependencies | 5 |
| Unpacked size | 295.6 KB |
| Known vulnerabilities | 0 (+24 in 2 direct dependencies) |
| Install scripts | no |
| Author | Nicholas Newman |
| Maintainers | nicholas-newman1 |

## Links

- npm: https://www.npmjs.com/package/firebase-auth-functions
- npm.io page: https://npm.io/package/firebase-auth-functions

## Dependencies (5)

- [axios](https://npm.io/package/axios.md) ^0.24.0
- [firebase](https://npm.io/package/firebase.md) ^8.x.x
- [firebase-admin](https://npm.io/package/firebase-admin.md) 9.x.x
- [@material-ui/core](https://npm.io/package/@material-ui/core.md) ^4.12.3
- [firebase-functions](https://npm.io/package/firebase-functions.md) 3.x.x

## Recent versions

- 1.0.2 (latest) — 2021-12-25
- 1.0.1 — 2021-10-30
- 1.0.0 — 2021-10-30

## README

## Getting Started

This package contains pre-built firebase cloud functions and is intended to be used in conjuction with [react-redux-firebase-auth](https://www.npmjs.com/package/react-redux-firebase-auth)

```
npm i firebase-auth-functions
```

### Using Firebase Auth Functions

#### Environment Variables

First, set a couple of environemnt variables:

```
firebase functions:config:set fb.ap_key=[API_KEY]
```

```
firebase functions:config:set runtime.env=production
```

If you wish to use the firebase emulator, set its environment variables by creating .runtimeconfig.json with the following:

```json
{
  "fb": {
    "api_key": "[API_KEY]"
  },
  "runtime": {
    "env": "development"
  }
}
```

Remember to add .runtimeconfig.json to .gitignore

#### Functions Code

```js
import * as functions from 'firebase-functions';
import * as admin from 'firebase-admin';
import getFunctions from 'firebase-auth-functions';
admin.initializeApp();

export const { signUp, signIn, editProfile } = getFunctions(admin, functions);
```

### Typescript errors when building?

Add "skipLibCheck": true to tsconfig.

- Clears errors
- Significant performance increase by skipping checking .d.ts files, particularly those in node_modules
- Recommended by TS

---
_Source: https://npm.io/package/firebase-auth-functions · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
