Press n or j to go to the next uncovered block, b, p or k for the previous block.
| 1 2 3 4 5 6 7 8 9 10 | 2x 2x 8x 8x | import { isBrowser } from '@wirewheel/cmp/src/utils/isBrowser'
export function convertToBase64(text: string) {
Iif (isBrowser()) {
return window.btoa(text)
} else {
return Buffer.from(text).toString('base64')
}
}
|