Skip to content

Latest commit

 

History

History
19 lines (11 loc) · 324 Bytes

formatToBase64.md

File metadata and controls

19 lines (11 loc) · 324 Bytes

formatToBase64

Add prefix to Base64

Arguments

  • value: String: A value to be base64

Returns

  • string: String: A string formatted with the base64 prefix

Usage

import { formatToBase64 } from '@platformbuilders/helpers'

formatToBase64('dGVzdA=='); // return 'data:image/png;base64,dGVzdA=='