[READ-ONLY] Mirror of https://github.com/mrgnw/morganwill.com. morganwill.com
0

Configure Feed

Select the types of activity you want to include in your feed.

update link serialization

+14 -9
+14 -9
src/routes/+page.server.js
··· 34 34 ] 35 35 36 36 export async function load() { 37 - await Promise.all(all_links.map(async (link) => { 38 - link.qr = await QRCode.toString( 39 - link.url, { 40 - type: 'svg', 41 - width: 164, 42 - } 43 - ); 44 - })); 37 + const links = await Promise.all( 38 + all_links.map(async (link) => { 39 + const qr = await QRCode.toString(link.url, { 40 + type: "svg", 41 + width: 164, 42 + } 43 + ); 44 + return { 45 + ...link, 46 + qr 47 + }; 48 + }) 49 + ); 45 50 46 51 return { 47 - all_links 52 + all_links: links 48 53 }; 49 54 }