Files
speckle-server/packages/frontend-2/lib/common/helpers/tailwind.ts
T
Kristaps Fabians Geikins 83d8035dc2 chore: upgrade to eslint 9 (#2348)
* root + server

* frontend

* frontend-2

* dui3

* dui3

* tailwind theme

* ui-components

* preview service

* viewer

* viewer-sandbox

* fileimport-service

* webhook service

* objectloader

* shared

* ui-components-nuxt

* WIP full config

* WIP full linter

* eslint projectwide util

* minor fix

* removing redundant ci

* clean up test errors

* fixed prettier formatting

* CI improvements

* TSC lint fix

* 'buildBatch' needs to be async since some batch types (like Text) require it. Removed a disabled liniting rule from ObjLoader

* removed unnecessary void

---------

Co-authored-by: AlexandruPopovici <alexandrupopoviciioan@gmail.com>
2024-06-12 14:38:02 +03:00

19 lines
762 B
TypeScript

import { TailwindBreakpoints } from '@speckle/ui-components'
/**
* If you use concatenation or variables to build tailwind classes, PurgeCSS won't pick up on them
* during build and will not add them to the build. So you can use this function to just add string
* literals of tailwind classes so PurgeCSS picks up on them.
*
* While you could just define an unused array of these classes, eslint/TS will bother you about the unused
* variable so it's better to use this instead.
*/
export function markClassesUsed(classes: string[]) {
// this doesn't do anything, we just need PurgeCSS to be able to read
// invocations of this function
// eslint-disable-next-line no-constant-binary-expression
false && classes
}
export { TailwindBreakpoints }