Skip to content

Instantly share code, notes, and snippets.

@lithin
Created July 6, 2016 14:02
Show Gist options
  • Save lithin/f10ff3c9caf808bc08642fd49c68187b to your computer and use it in GitHub Desktop.
Save lithin/f10ff3c9caf808bc08642fd49c68187b to your computer and use it in GitHub Desktop.
import { toClj } from 'mori';
async function getUser() {
// fetch json data from our API
const user = await fetch('http://api.com/user');
const userJson = await user.json();
// convert the object into a clojure's hashMap
return toClj(userJson);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment