Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

URLs resolve incorrectly in subfolders #15269

Closed
sweetroll opened this issue Dec 2, 2024 · 1 comment · Fixed by #15275
Closed

URLs resolve incorrectly in subfolders #15269

sweetroll opened this issue Dec 2, 2024 · 1 comment · Fixed by #15275

Comments

@sweetroll
Copy link

What version of Tailwind CSS are you using?

tailwindcss 4.0.0-beta.4

What build tool (or framework if it abstracts the build tool) are you using?

vite 5.4.11
tailwindcss/vite 4.0.0-beta.4

What version of Node.js are you using?

20.17.0

What browser are you using?

Brave

What operating system are you using?

MacOS

Reproduction URL

https://github.com/sweetroll/tailwind-url-issue

Describe your issue

Adding background images to CSS files in a subfolder results in broken images. The reproduction has 4 divs, each has a background image set. Div 1 and 2 reference images in an images folder and the public folder respectively. These styles are in the main css file and work fine. Div 3 and 4 reference the same images but the styles are in a subfolder which breaks. The URLs resolve to paths using the subfolder eg. /images/vite.svg -> ./subfolder/images/vite.svg

@thecrypticace
Copy link
Contributor

This will be fixed in the next beta release 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants