| | |
| | | } |
| | | |
| | | if (opts?.enableSiteMap) { |
| | | emitted.push(await emit({ |
| | | emitted.push( |
| | | await emit({ |
| | | content: generateSiteMap(cfg, linkIndex), |
| | | slug: "sitemap" as ServerSlug, |
| | | ext: ".xml", |
| | | })) |
| | | }), |
| | | ) |
| | | } |
| | | |
| | | if (opts?.enableRSS) { |
| | | emitted.push(await emit({ |
| | | emitted.push( |
| | | await emit({ |
| | | content: generateRSSFeed(cfg, linkIndex), |
| | | slug: "index" as ServerSlug, |
| | | ext: ".xml", |
| | | })) |
| | | }), |
| | | ) |
| | | } |
| | | |
| | | const fp = path.join("static", "contentIndex") as ServerSlug |
| | |
| | | }), |
| | | ) |
| | | |
| | | emitted.push(await emit({ |
| | | emitted.push( |
| | | await emit({ |
| | | content: JSON.stringify(simplifiedIndex), |
| | | slug: fp, |
| | | ext: ".json", |
| | | })) |
| | | }), |
| | | ) |
| | | |
| | | return emitted |
| | | }, |