deta-space-bare-client
v3.0.2
Published
Access the Deta Space API from the browser.
Downloads
3
Readme
Deta Bare Client
API Wrapper for Deta Space, implementing the TompHTTP specifications
Usage
See the Authentication Doc for more information on how to get your access token.
bare
.createBareClient(`http://${window.location.host}/bare/`)
.then(async (client) => {
const spaceFetch = detaBareClient.fetchFn(
prompt("Deta Space Token"),
client
);
spaceFetch("/apps")
.then((res) => res.json())
.then((payload) => {
console.log(payload);
})
.catch((err) => {
console.error(err);
});
});