mirror of
https://github.com/NohamR/lanyard-profile-readme.git
synced 2026-05-25 20:00:40 +00:00
🌟 Code Cleanup
This commit is contained in:
@@ -1,3 +1,13 @@
|
||||
import imageToBase64 from "image-to-base64";
|
||||
|
||||
export const encodeBase64 = async (url: string): Promise<string> => await imageToBase64(url);
|
||||
export const encodeBase64 = async (url: string): Promise<string> => {
|
||||
let response = "";
|
||||
|
||||
try {
|
||||
response = await imageToBase64(url);
|
||||
} catch (e) {
|
||||
console.log(e)
|
||||
}
|
||||
|
||||
return response;
|
||||
}
|
||||
Reference in New Issue
Block a user