Skip to content
Discussion options

You must be logged in to vote

I found a reponse here.
The answer is using the base url. https://vite.dev/guide/build.html#public-base-path

export default defineConfig({
  base: '',
  })

This solves the problem. The url is correctly written as :../fonts/font-a.woff from then on.

Replies: 5 comments 2 replies

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
2 replies
@WaningJupiter
Comment options

@alanbabychan
Comment options

Comment options

You must be logged in to vote
0 replies
Answer selected by WaningJupiter
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
5 participants
⌂ 换网址