this repo has no description
1
fork

Configure Feed

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

✨ Tech includes

+16 -6
+2
src/content.config.ts
··· 215 215 "technologies.yaml", 216 216 z.object({ 217 217 isAliasOf: z.string().nullable().default(null), 218 + aliases: z.array(z.string()).optional().default([]), 218 219 slug: z.string(), 219 220 name: z.string(), 220 221 by: z.string().optional(), ··· 222 223 "learn more at": z.string().url().optional(), 223 224 description: z.string().optional(), 224 225 autodetect: z.array(z.string()).optional(), 226 + includes: z.array(z.string()).optional(), 225 227 }), 226 228 (tech) => tech.name, 227 229 (tech) => tech.aliases,
+14 -6
src/pages/using/[tech].astro
··· 22 22 ); 23 23 if (!tech) return Astro.rewrite("/404"); 24 24 25 + const includedTechs = [ 26 + tech.id, 27 + ...(tech.data.includes ?? []), 28 + ]; 29 + 25 30 const works = await getCollection("works").then((works) => 26 31 works 27 32 .filter( 28 33 ({ data: work }) => 29 34 !work.metadata.private && 30 - (work.metadata.madeWith?.some( 31 - (mw) => resolveAliased(mw.id, technologies) === tech.id, 32 - ) || 33 - work.metadata.additionalMetadata?.made_with 34 - ?.map((id) => resolveAliased(id, technologies)) 35 - .includes(tech.id)), 35 + includedTechs.some( 36 + (includedTech) => 37 + work.metadata.madeWith?.some( 38 + (mw) => resolveAliased(mw.id, technologies) === includedTech, 39 + ) || 40 + work.metadata.additionalMetadata?.made_with 41 + ?.map((id) => resolveAliased(id, technologies)) 42 + .includes(includedTech), 43 + ), 36 44 ) 37 45 .map((w) => w.data), 38 46 );