mirror of
https://github.com/sern-handler/website
synced 2026-06-26 09:42:24 +00:00
feat: migrate to starlight
This commit is contained in:
18
node_modules/astro-expressive-code/components/page-data.ts
generated
vendored
Normal file
18
node_modules/astro-expressive-code/components/page-data.ts
generated
vendored
Normal file
@@ -0,0 +1,18 @@
|
||||
export type PageData = {
|
||||
url: string
|
||||
blockGroupIndex: number
|
||||
}
|
||||
|
||||
const pageDataMap = new Map<Request, PageData>()
|
||||
|
||||
export function getPageData(request: Request): PageData {
|
||||
let data = pageDataMap.get(request)
|
||||
if (!data) {
|
||||
data = {
|
||||
url: request.url,
|
||||
blockGroupIndex: -1,
|
||||
}
|
||||
pageDataMap.set(request, data)
|
||||
}
|
||||
return data
|
||||
}
|
||||
Reference in New Issue
Block a user