UNPKG

rxdb-server

Version:
20 lines (19 loc) 505 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.postRequest = postRequest; async function postRequest(url, body, headers = {}) { var request = await fetch(url, { method: 'POST', credentials: 'include', headers: Object.assign({ 'Accept': 'application/json', 'Content-Type': 'application/json' }, headers), body: JSON.stringify(body) }); var response = await request.json(); return response; } //# sourceMappingURL=utils.js.map