This is my package description.
Install package:
# npm
npm install tslx
# yarn
yarn add tslx
# pnpm
pnpm install tslx
Import:
// ESM
import { cls } from "tslx";
// CommonJS
// const { cls } = require("tslx");
cls("foo", "bar", {
"text-white": true,
"bg-red": false,
});
// => "foo bar text-white"
- Clone this repository
- Install latest LTS version of Node.js
- Enable Corepack using
corepack enable
- Install dependencies using
pnpm install
- Run interactive tests using
pnpm dev
tslx
is made possible thanks to the inspirations from the following projects:
- clsx A tiny (228B) utility for constructing
className
strings conditionally.
Made with 💛
Published under MIT License.