mirror of
https://github.com/Afilmory/afilmory
synced 2026-02-01 22:48:17 +00:00
feat: update site configuration and enhance feed structure
- Changed project name and title in the site configuration to "Innei's Afilmory". - Updated author name in the configuration to "Innei" and adjusted the URL accordingly. - Added a new feed structure in the configuration to include follow challenge details. - Enhanced the feed sitemap generation to incorporate the new feed data. Signed-off-by: Innei <tukon479@gmail.com>
This commit is contained in:
@@ -4,6 +4,8 @@ import { fileURLToPath } from 'node:url'
|
||||
|
||||
import type { Plugin } from 'vite'
|
||||
|
||||
import type { SiteConfig } from '../../site.config'
|
||||
|
||||
interface PhotoData {
|
||||
id: string
|
||||
title: string
|
||||
@@ -24,18 +26,6 @@ interface PhotoData {
|
||||
isLivePhoto: boolean
|
||||
}
|
||||
|
||||
interface SiteConfig {
|
||||
name: string
|
||||
title: string
|
||||
description: string
|
||||
url: string
|
||||
author: {
|
||||
name: string
|
||||
url: string
|
||||
avatar?: string
|
||||
}
|
||||
}
|
||||
|
||||
const __dirname = fileURLToPath(new URL('.', import.meta.url))
|
||||
|
||||
export function createFeedSitemapPlugin(siteConfig: SiteConfig): Plugin {
|
||||
@@ -135,6 +125,17 @@ ${exifTags}
|
||||
<lastBuildDate>${lastBuildDate}</lastBuildDate>
|
||||
<pubDate>${now}</pubDate>
|
||||
<ttl>60</ttl>
|
||||
<copyright>Copyright ${config.author.name}</copyright>
|
||||
${
|
||||
config.feed?.folo?.challenge
|
||||
? `
|
||||
<follow_challenge>
|
||||
<feedId>${config.feed?.folo?.challenge.feedId}</feedId>
|
||||
<userId>${config.feed?.folo?.challenge.userId}</userId>
|
||||
</follow_challenge>
|
||||
`
|
||||
: ''
|
||||
}
|
||||
<atom:link href="${config.url}/feed.xml" rel="self" type="application/rss+xml" />
|
||||
<managingEditor>${config.author.name}</managingEditor>
|
||||
<webMaster>${config.author.name}</webMaster>
|
||||
|
||||
Reference in New Issue
Block a user