async function shareToPlayground(groups, groupName) {
  let url = (await (await fetch(`${PLAYGROUND}/v1/share`, createDataRequestOpts(groups, groupName))).json()).result
  if (!url) {
    throw new Error("Unable to get URL from the playground's response.")
  }
  return url
}
// Either resolves to a playground url with the group's content or rejects with a (non-user-friendly) error.
Either resolves to a playground url with the group's content or rejects with a (non-user-friendly) error.
Either resolves to a playground url with the group ' s content or rejects with a ( non - user - friendly ) error .
async function shareToPlayground(groups, groupName) {
  let url = (await (await fetch(`${PLAYGROUND}/v1/share`, createDataRequestOpts(groups, groupName))).json()).result
  if (!url) {
    throw new Error("Unable to get URL from the playground's response.")
  }
  return url
}
async function shareToPlayground ( groups , groupName ) { let url = ( await ( await fetch ( ` ${ PLAYGROUND } ` , createDataRequestOpts ( groups , groupName ) ) ) . json ( ) ) . result if ( ! url ) { throw new Error ( "Unable to get URL from the playground's response." ) } return url }
Either resolves to a playground url with the group's content or rejects with a (non-user-friendly) error.
Either resolves to a playground url with the group ' s content or rejects with a ( non - user - friendly ) error .