-
Notifications
You must be signed in to change notification settings - Fork 329
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
[bug]: Paradoxical bug with using withUt or the style itself #975
Comments
is your repo a monorepo? if you log the outputted tailwind config, do any uploadthing paths get added to content? I've run into edge cases where the paths cannot be auto-found. If so you can add the path to const config = withUt({
// your config
})
console.log(config) // does this have `content: ["/path/to/node_modules/@uploadthing/svelte/dist/**"]`
export default config |
This is what the console logs: {
darkMode: [ 'class' ],
content: [ './src/**/*.{html,js,svelte,ts}' ],
safelist: [ 'dark' ],
theme: {
container: { center: true, padding: '2rem', screens: [Object] },
extend: { colors: [Object], borderRadius: [Object], fontFamily: [Object] }
},
plugins: [
[Function: optionsFunction] {
__isOptionsFunction: true,
__pluginFunction: [Function (anonymous)],
__configFunction: [Function (anonymous)]
},
{ handler: [Function (anonymous)], config: undefined }
]
} |
? Also, What PM are you using? It's hard to auto-detect the paths in all scenarios. Sometimes |
Yes, it's a mono repo. Where should I add the required resolve tag |
Are you able to provide a reproduction? Without that, the only advise I can give is to manually add the content paths export default withUt({
// your config
content: [
'./src/**/*.{html,js,svelte,ts}',
'./node_modules/@uploadthing/svelte/dist/**',
'../../node_modules/@uploadthing/svelte/dist/**', // or .. back to root, depending on where your package manager keeps the uploadthing distribution
]
}) |
Doing it manually works. repro would be hard as its a very large project |
No worries I managed to reproduce it in the solid example: 1d23a77#diff-c91c28746f5b2978ef621d788f91af58b065126119189296cd628141787aa8cd Guess it's something odd with Vite cause if i Will investigate further, but hardcoded paths is a valid workaround for now |
Many thanks again @juliusmarminge |
Fixed in #987. Will be released in the next patch update |
Provide environment information
Describe the bug
Using
withUt
breaks the upload button whereas using the@uploadthing/svelte/styles.css
stylesheet by itself without including thewithUT
utility breaks the navbar.WithUT
does not show any loading state when I begin uploading as shown below:Using the @uploadthing/svelte/styles.css stylesheet import before my
global.cssbreaks my navbar as shown below
which should look like:
Note Im only using withUt and the style by itself when testing this behavior
Link to reproduction
N/A
To reproduce
Add the
withUT
utility or the styles to a fresh Sveltekit installation with tailwind installed. But Not Both!Additional information
I have tried clearing my
bun.lockb
andnode-modules
directory and reinstalling the packages. None resolves the issue specifically on deployment to either Vercel or my personal VPS. The stylesheet inclusion works on the dev server however breaks the styles and the navbar on deployment👨👧👦 Contributing
Code of Conduct
The text was updated successfully, but these errors were encountered: