6 lines
352 B
TypeScript
6 lines
352 B
TypeScript
// Joins class names, dropping anything falsy. Every class this package emits is
|
|
// a primitive that already exists in the site's own stylesheet - these
|
|
// components add no CSS of their own, so the look can never drift from the site.
|
|
export const cx = (...parts: Array<string | false | null | undefined>): string =>
|
|
parts.filter(Boolean).join(' ');
|