JSFiddle - React, Tailwind, and code Playground
by Artem
Babel + JSX
'use strict';
const foo = async () => 'Hello world';
const callbackify = fn =>
cb =>
fn.then(v => cb(null, v), e => cb(e, null));
by Artem
'use strict';
const foo = async () => 'Hello world';
const callbackify = fn =>
cb =>
fn.then(v => cb(null, v), e => cb(e, null));