# extension-to-functions-codebase

> Claude/Codex skill by [@firebase](https://omgskills.com/library/firebase/index.md) · 491 stars · Updated 2026-10-28

Skill for converting an installed Firebase Extension (or extension source) into a standalone Cloud Functions for Firebase codebase or publishable npm package, including V1 to V2 trigger upgrades, lifecycle hooks, and declarative security

## Install

```sh
git clone https://github.com/firebase/agent-skills /tmp/agent-skills && ln -s /tmp/agent-skills/skills/extension-to-functions-codebase ~/.claude/skills/extension-to-functions-codebase
```

## From README

Extension to Functions Codebase & npm Package Migration Overview Migrates a Firebase Extension into either: A local Cloud Functions codebase (functions/src/ for app integration). A publishable npm package (reusable open-source package exporting V2 functions). Leverages native Cloud Functions features (declarative IAM, Parameterized Config, SDK Lifecycle Hooks) and modernizes 1st Gen triggers to 2nd Gen using the Destructuring Compatibility Shim. Target Migration Workflows Target A: Local Functions Codebase (End-User App Integration) Output: Code under functions/src/. Config in .env. Deployment: firebase deploy --only functions. Target B: Publishable npm Package / Shareable Package Output: Reusable npm package exporting V2 functions. Configuration: package.json specifying exports map, engines: { "node": "\>=22" }, and peerDependencies: { "firebase-functions": "\>=6.0.0" }. Consumers package and re-export functions in index.ts (export from " ").

## Links

- HTML page: https://omgskills.com/library/firebase/agent-skills/skills/extension-to-functions-codebase/
- GitHub: https://github.com/firebase/agent-skills
- Author: [@firebase](https://omgskills.com/library/firebase/index.md)

## More from this repo

- [firebase-app-hosting-basics](https://omgskills.com/library/firebase/skills/firebase-app-hosting-basics/index.md) — Deploys and manages full-stack web applications (Next.js, Angular) with Server-Side Rendering (SSR) using Firebase App...
   - [@firebase](https://omgskills.com/library/firebase/index.md) · 491 stars
- [firebase-basics](https://omgskills.com/library/firebase/skills/firebase-basics/index.md) — Provides foundational Firebase CLI setup, CLI installation, version checks (\`firebase-tools@latest --version\`), CLI...
   - [@firebase](https://omgskills.com/library/firebase/index.md) · 491 stars
- [firebase-ai-logic-basics](https://omgskills.com/library/firebase/skills/firebase-ai-logic/index.md) — Integrates Firebase AI Logic (formerly Vertex AI for Firebase) into mobile and web apps (Android, iOS, Web, and...
   - [@firebase](https://omgskills.com/library/firebase/index.md) · 472 stars
