Install & Compatibility
Where this runs
tested against v? · npm install
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslnode 18–223 runs
build_error
glibcnode 18–223 runs
build_error
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
default export (jess)
✓ import jess from 'rollup-plugin-jess'
✗ const jess = require('rollup-plugin-jess');
ESM only; CommonJS require will not work because the package is type: module and uses ESM syntax. For Rollup configs in CJS, use dynamic import: const jess = (await import('rollup-plugin-jess')).default;
jess (as named export)
✓ import { jess } from 'rollup-plugin-jess'
✗ import jess from 'rollup-plugin-jess'
The plugin also exports a named export `jess` which is the same as default. Both work, but importing as default is more idiomatic due to single-function usage.
type JessOptions
✓ import type { JessOptions } from 'rollup-plugin-jess'
✗ import { JessOptions } from 'rollup-plugin-jess' (if used at runtime)
TypeScript declaration ships with the package; JessOptions is exported as a named type for plugin configuration. Only import as type to avoid runtime inclusion.
Rollup configuration importing the jess plugin, converting Jess files in the build pipeline.
// rollup.config.js
import jess from 'rollup-plugin-jess';
import { defineConfig } from 'rollup';
export default defineConfig({
input: 'src/main.js',
output: {
file: 'dist/bundle.js',
format: 'esm'
},
plugins: [
jess({
// Jess configuration options (see jesscss.github.io)
// e.g., compress: false
})
]
});
Errors
Common errors & fixes
Error: Cannot find module 'rollup-plugin-jess'
Plugin not installed or npm install incomplete.
fixRun `npm install rollup-plugin-jess --save-dev` (or yarn equivalent) in project root.
TypeError: jess is not a function
Using CommonJS require in an ESM-only package; jess is the default export but not available via require as a function.
fixUse dynamic import: const jess = (await import('rollup-plugin-jess')).default; in CommonJS context, or convert rollup.config.js to ES module. Error: Peer dependency rollup@^2.0.0 not installed
Rollup is missing or version mismatch (e.g., Rollup 3.x installed).
fixInstall Rollup 2.x: `npm install rollup@^2.0.0 --save-dev`.
Upgrade
Version history
1.0.8-alpha.8latest on npm
Audit
Dependencies
rolluprequiredPeer dependency; plugin requires Rollup >=2.0.0 to hook into the build pipeline.