0
Fork 0
mirror of https://github.com/withastro/astro.git synced 2024-12-30 22:03:56 -05:00
astro/packages/integrations/image/src
Vincent Tavernier e58a92527f
[@astrojs/image] Handle missing trailing slash in processStaticImage (#6421)
The code path changed by this commit isn't only taken when running using Vite. If the site is configured with a base url which is different from `/` but does **not** end with `/` (for example, because `trailingSlash` is set to `never`), the `- 1` results in an off-by-one error when truncating the URL.

By checking if the base url ends with `/`, we can determine the right length for the prefix to truncate.
2023-03-07 13:00:34 -05:00
..
build [@astrojs/image] Handle missing trailing slash in processStaticImage (#6421) 2023-03-07 13:00:34 -05:00
lib chore: use directive @ts-expect-error instead of @ts-ignore (#6429) 2023-03-07 13:41:24 +00:00
loaders chore: use directive @ts-expect-error instead of @ts-ignore (#6429) 2023-03-07 13:41:24 +00:00
utils Fix image integration not working on Node 18+ (#5871) 2023-01-17 15:48:06 +01:00
vendor/squoosh [ci] format 2023-03-07 13:43:21 +00:00
endpoint.ts chore: use directive @ts-expect-error instead of @ts-ignore (#6429) 2023-03-07 13:41:24 +00:00
index.ts Output assets to _astro directory (#5772) 2023-01-09 10:01:33 -06:00
vite-plugin-astro-image.ts Add support for SVG images to  @astrojs/image (#6118) 2023-02-15 09:21:41 +01:00