![require(esm) Backported to Node.js 20, Paving the Way for ESM-Only Packages](https://cdn.sanity.io/images/cgdhsj6q/production/be8ab80c8efa5907bc341c6fefe9aa20d239d890-1600x1097.png?w=400&fit=max&auto=format)
Security News
require(esm) Backported to Node.js 20, Paving the Way for ESM-Only Packages
require(esm) backported to Node.js 20, easing the transition to ESM-only packages and reducing complexity for developers as Node 18 nears end-of-life.
@qctrl/elements-css
Advanced tools
Elements CSS is a utility framework for building Q-CTRL products. It’s built upon Tailwind and designed to match the Element Design Library by using the design tokens.
Q-CTRL Elements CSS is a utility framework for building Q-CTRL products. It’s built upon Tailwind and designed to match the Element Design Library by using the design tokens. It also introduces several base, component, and utility classes to make working with Elements CSS easier and more versatile. As such our documentation builds upon Tailwind’s documentation to include these differences.
Depending on your project you may be using a specific framework that requires some additional setup. In this case we recommend you follow one of Tailwind’s framework guides and then jump ahead to Adding Elements CSS plugin.
npm install -D @qctrl/elements-css@latest tailwindcss@latest postcss@latest autoprefixer@latest
pnpm add -D @qctrl/elements-css@latest tailwindcss@latest postcss@latest autoprefixer@latest
For most projects, we recommend installing Elements CSS as a Tailwind plugin with PostCSS.
Add tailwindcss
and autoprefixer
to your PostCSS configuration. Most of the time this is a postcss.config.js
file at the root of your project, but it could also be a .postcssrc
file, or postcss key in your package.json
file.
To use the Elements CSS plugin you need to create a Tailwind config file and pass it as a plugin. You can generate the config file by using the Tailwind CLI utility included when you install the tailwindcss
npm package.
npx tailwindcss init
This will create a minimal tailwind.config.js file at the root of your project:
// tailwind.config.js
/** @type {import('tailwindcss').Config} */
module.exports = {
content: [],
theme: {
extend: {},
},
plugins: [],
};
// tailwind.config.js
/** @type {import('tailwindcss').Config} */
module.exports = {
+ content: [
+ "./src/**/*.{js,ts,jsx,tsx}",
+ // Any node_modules that use tailwindcss
+ ],
theme: {
extend: {},
},
+ plugins: [require("@qctrl/elements-css")],
};
@tailwind base;
@tailwind components;
@tailwind utilities;
FAQs
Elements CSS is a utility framework for building Q-CTRL products. It’s built upon Tailwind and designed to match the Element Design Library by using the design tokens.
The npm package @qctrl/elements-css receives a total of 340 weekly downloads. As such, @qctrl/elements-css popularity was classified as not popular.
We found that @qctrl/elements-css demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
require(esm) backported to Node.js 20, easing the transition to ESM-only packages and reducing complexity for developers as Node 18 nears end-of-life.
Security News
PyPI now supports iOS and Android wheels, making it easier for Python developers to distribute mobile packages.
Security News
Create React App is officially deprecated due to React 19 issues and lack of maintenance—developers should switch to Vite or other modern alternatives.