MedicOneSystems / livewire-datatables

Advanced datatables using Laravel, Livewire, Tailwind CSS and Alpine JS
https://livewire-datatables.com/
MIT License
1.2k stars 259 forks source link

npm run prod breaks table css #161

Closed gathuku closed 3 years ago

gathuku commented 3 years ago

When run npm run prod table CSS breaks and its working well with npm run dev

FaycalBorsali commented 3 years ago

When run npm run prod table CSS breaks and its working well with npm run dev

I have the same problem, I see that you closed it yourself how did you solve it ? @gathuku

gathuku commented 3 years ago

@FaycalBorsali it was an issue with purge CSS which was not including this package style. Maybe this can help which include a path to this package resources

    purge: {
        content: [
            './app/**/*.php',
            './resources/**/*.html',
            './resources/**/*.js',
            './resources/**/*.jsx',
            './resources/**/*.ts',
            './resources/**/*.tsx',
            './resources/**/*.php',
            './resources/**/*.vue',
            './resources/**/*.twig',
            './vendor/mediconesystems/livewire-datatables/resources/**/*.php'
        ],
        options: {
            defaultExtractor: (content) => content.match(/[\w-/.:]+(?<!:)/g) || [],
            whitelistPatterns: [/-active$/, /-enter$/, /-leave-to$/, /show$/],
        },
    },
FaycalBorsali commented 3 years ago

@gathuku that works perfectly, thank you