CSS missing for some components on Vite bundle

Viewed 393

The title really says it all, some components have their CSS included correctly and others are missing the CSS altogether. There is no difference between the working and non-working components that I can find, but each time I run the build script, the same components are missing the CSS. The CSS files are being imported normally -

import "./WeeklyTrend.css"

I'm using Vite as my bundler, I have not made any changes to the config beyond what comes with the react template, which I will include below.

import { defineConfig } from 'vite'
import react from '@vitejs/plugin-react'

export default defineConfig({
   plugins: [react()],
   base: "https://www.--fakeserverurl--.com/"
})

The css in question is missing altogether from the bundled CSS file. I'm probably missing something simple, but I really have looked all over the place with no success. Thanks in advance.

0 Answers
Related