mirror of
https://github.com/4gray/iptvnator.git
synced 2026-10-10 01:56:16 -08:00
`website:lint` failed on master since the per-OS download pages landed:
`src/lib/downloads.ts` imported the workspace root `package.json` through a
relative path, which `@nx/enforce-module-boundaries` rejects ("external
resources cannot be imported using a relative or absolute path").
The value is only needed as a build-time constant for the offline fallback,
so `astro.config.mjs` now reads the root manifest through the file system
and injects `__IPTVNATOR_VERSION__` via Vite `define`; `downloads.ts` uses
that constant and `src/env.d.ts` declares its type. Verified with
`WEBSITE_SKIP_RELEASE_FETCH=1`: the built download pages link the
`iptvnator-<version>` assets and no define literal leaks into the output.
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
9 lines
300 B
TypeScript
9 lines
300 B
TypeScript
/// <reference types="astro/client" />
|
|
|
|
/**
|
|
* Repository version from the workspace root `package.json`, injected at
|
|
* build time by `astro.config.mjs` through Vite `define`. Used by the download
|
|
* pages' offline fallback (`src/lib/downloads.ts`).
|
|
*/
|
|
declare const __IPTVNATOR_VERSION__: string;
|