9 lines
287 B
TypeScript
9 lines
287 B
TypeScript
export const cIf = (
|
|
condition: boolean | string | null | undefined,
|
|
ifTrueCss: string,
|
|
ifFalseCss?: string
|
|
): string => (condition ? ifTrueCss : ifFalseCss ?? "");
|
|
|
|
export const cJoin = (...args: (string | undefined)[]): string =>
|
|
args.filter((elem) => elem).join(" ");
|