Skip to content

Instantly share code, notes, and snippets.

@nehemiahj
Created March 14, 2024 19:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save nehemiahj/67350d473e74238f93c899d73696fcda to your computer and use it in GitHub Desktop.
Save nehemiahj/67350d473e74238f93c899d73696fcda to your computer and use it in GitHub Desktop.
Vercel Edge Config
import { get, has, getAll } from '@vercel/edge-config';
// To read a single key
const someValue = await get("someKey")
// To check if a key exists
const someValue = await has('someKey');
// To read all the items in data store
const someValue = await getAll();
// To read items in batch
const someValue = await getAll(['keyA', 'keyB']);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment