unpkg/modules/utils/createDataURI.js

4 lines
133 B
JavaScript

export default function createDataURI(contentType, content) {
return `data:${contentType};base64,${content.toString('base64')}`;
}