diff --git a/.gitignore b/.gitignore index 877dd4cb2..2981e8b0e 100644 --- a/.gitignore +++ b/.gitignore @@ -1,7 +1,5 @@ # See https://docs.github.com/en/get-started/getting-started-with-git/ignoring-files for more about ignoring files. - /.cache -!/.cache/vite/.gitkeep # compiled output dist diff --git a/apps/server/src/services/asset_path.ts b/apps/server/src/services/asset_path.ts index 237a3f5a3..2e14996e4 100644 --- a/apps/server/src/services/asset_path.ts +++ b/apps/server/src/services/asset_path.ts @@ -1,7 +1,14 @@ import packageJson from "../../package.json" with { type: "json" }; import { isDev } from "./utils"; +/** + * The URL prefix for assets (e.g. `assets/v1.2.3`). + */ export const assetUrlFragment = `assets/v${packageJson.version}`; + +/** + * Similar to the {@link assetUrlFragment}, but on dev mode it also contains the `/src` suffix. + */ const assetPath = isDev ? assetUrlFragment + "/src" : assetUrlFragment; export default assetPath;