@daaku/firebase-rest-api
Advanced tools
Comparing version 0.1.0 to 0.1.1
@@ -1,7 +0,4 @@ | ||
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.makeFirebaseAPI = exports.FirebaseConfig = void 0; | ||
// FirebaseConfig holds the base configuration and provides helpers to build | ||
// paths & URLs in the context of that configuration. | ||
class FirebaseConfig { | ||
export class FirebaseConfig { | ||
constructor({ apiKey, projectID, databaseID = '(default)', host = 'firestore.googleapis.com', protocol = 'https', }) { | ||
@@ -22,6 +19,5 @@ this.apiKey = apiKey; | ||
} | ||
exports.FirebaseConfig = FirebaseConfig; | ||
// Make an API instance pre-configured with the endpoint. It will fetch a token | ||
// from the TokenSource on each API call. | ||
function makeFirebaseAPI({ config, tokenSource, next = fetch, }) { | ||
export function makeFirebaseAPI({ config, tokenSource, next = fetch, }) { | ||
return async (method, path, body) => { | ||
@@ -50,3 +46,2 @@ const init = { method }; | ||
} | ||
exports.makeFirebaseAPI = makeFirebaseAPI; | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "@daaku/firebase-rest-api", | ||
"author": "Naitik Shah <n@daaku.org>", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"description": "Minimal wrapper around fetch to make Firebase REST API calls.", | ||
@@ -26,11 +26,11 @@ "repository": "git@github.com:daaku/firebase-rest-api", | ||
"devDependencies": { | ||
"@daaku/qunit-puppeteer": "^0.1.1", | ||
"@types/qunit": "^2.9.1", | ||
"esbuild": "^0.7.1", | ||
"eslint": "^7.9.0", | ||
"eslint-config-daaku": "^2.0.0", | ||
"@daaku/eslint-config": "^3.0.0", | ||
"@daaku/qunit-puppeteer": "^0.1.3", | ||
"@types/qunit": "^2.9.5", | ||
"esbuild": "^0.7.15", | ||
"eslint": "^7.11.0", | ||
"npm-run-all": "^4.1.5", | ||
"qunit": "^2.11.2", | ||
"typescript": "^4.0.2" | ||
"qunit": "^2.11.3", | ||
"typescript": "^4.0.3" | ||
} | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
6742
72