Skip to content

Instantly share code, notes, and snippets.

@chrisoverstreet chrisoverstreet/actions.js
Last active May 23, 2018

Embed
What would you like to do?
Cosmic Blog tutorial - Fetch post
const fetchPost = slug => fetch(`${API_URL}/post/${slug}`)
.then(res => res.json())
.then(json => console.log(json));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.