From 45e71a860e5beffd7b894b64d9b204767887a9dd Mon Sep 17 00:00:00 2001 From: Dominic Bartl Date: Wed, 28 Jun 2023 15:33:34 +0200 Subject: [PATCH 1/2] Allow $schema property in firebase.json --- schema/firebase-config.json | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/schema/firebase-config.json b/schema/firebase-config.json index ca1f66754b1..574ed1bcb59 100644 --- a/schema/firebase-config.json +++ b/schema/firebase-config.json @@ -128,6 +128,10 @@ } }, "properties": { + "$schema": { + "type": "string", + "format": "uri" + }, "database": { "anyOf": [ { From 02b10d053bfc3da10801421418f3ccc50e8ba059 Mon Sep 17 00:00:00 2001 From: Dominic Bartl Date: Wed, 28 Jun 2023 16:00:39 +0200 Subject: [PATCH 2/2] Add $schema property via firebaseConfig.ts --- schema/firebase-config.json | 4 ++-- src/firebaseConfig.ts | 4 ++++ 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/schema/firebase-config.json b/schema/firebase-config.json index 574ed1bcb59..b4bb9139591 100644 --- a/schema/firebase-config.json +++ b/schema/firebase-config.json @@ -129,8 +129,8 @@ }, "properties": { "$schema": { - "type": "string", - "format": "uri" + "format": "uri", + "type": "string" }, "database": { "anyOf": [ diff --git a/src/firebaseConfig.ts b/src/firebaseConfig.ts index f1395ba13c7..9d76951f59c 100644 --- a/src/firebaseConfig.ts +++ b/src/firebaseConfig.ts @@ -234,6 +234,10 @@ export type EmulatorsConfig = { export type ExtensionsConfig = Record; export type FirebaseConfig = { + /** + * @TJS-format uri + */ + $schema?: string; database?: DatabaseConfig; firestore?: FirestoreConfig; functions?: FunctionsConfig;