{"id":21954,"library":"rollup-plugin-coffee-script","title":"rollup-plugin-coffee-script","description":"Rollup plugin that compiles CoffeeScript 2 files during bundling. Version 2.0.0 integrates CoffeeScript 2.x into Rollup builds without an extra build step. Unlike generic transpilers, it supports standard Rollup plugin options (include/exclude patterns) and pairs with rollup-plugin-commonjs and rollup-plugin-node-resolve for CommonJS interop and module resolution. Requires peer dependency coffeescript@2.x. Maintained by a single contributor on a best-effort cadence.","status":"active","version":"2.0.0","language":"javascript","source_language":"en","source_url":"https://github.com/lautis/rollup-plugin-coffee-script","tags":["javascript","rollup-plugin","coffeescript"],"install":[{"cmd":"npm install rollup-plugin-coffee-script","lang":"bash","label":"npm"},{"cmd":"yarn add rollup-plugin-coffee-script","lang":"bash","label":"yarn"},{"cmd":"pnpm add rollup-plugin-coffee-script","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Peer dependency: actual CoffeeScript compiler (2.x)","package":"coffeescript","optional":false}],"imports":[{"note":"ESM-only package; CommonJS require will fail unless in an ESM context.","wrong":"const coffee = require('rollup-plugin-coffee-script')","symbol":"default","correct":"import coffee from 'rollup-plugin-coffee-script'"},{"note":"Default export is the plugin function, not a named export.","wrong":"import { coffee } from 'rollup-plugin-coffee-script'","symbol":"coffee","correct":"import coffee from 'rollup-plugin-coffee-script'"},{"note":"Options object type is not exported; rely on JSDoc or source.","wrong":"import coffee from 'rollup-plugin-coffee-script'; coffee({ bare: true })","symbol":"Type usage","correct":"No TypeScript types provided; use @types or declare module."}],"quickstart":{"code":"// rollup.config.js\nimport coffee from 'rollup-plugin-coffee-script';\n\nexport default {\n  input: 'src/main.coffee',\n  output: { file: 'bundle.js', format: 'iife' },\n  plugins: [\n    coffee({\n      include: '**/*.coffee',\n      bare: true\n    })\n  ]\n};","lang":"javascript","description":"Minimal config: compile all .coffee files with 'bare' output (no top-level function wrapper)."},"warnings":[{"fix":"Add @rollup/plugin-commonjs and @rollup/plugin-node-resolve to plugins.","message":"Plugin does not resolve requires; you must add rollup-plugin-commonjs and rollup-plugin-node-resolve if your CoffeeScript uses require for Node modules.","severity":"gotcha","affected_versions":">=1.0"},{"fix":"Upgrade to CoffeeScript 2.x or pin to older plugin version (1.x).","message":"Version 2.0.0 drops CoffeeScript 1.x support; requires coffeescript@2.x.","severity":"breaking","affected_versions":">=2.0.0"},{"fix":"Replace 'filter' with 'include' minimatch pattern.","message":"The 'filter' option from very old versions is removed; use 'include'/'exclude'.","severity":"deprecated","affected_versions":">=2.0.0"}],"env_vars":null,"last_verified":"2026-04-27T00:00:00.000Z","next_check":"2026-07-26T00:00:00.000Z","problems":[{"fix":"Run 'npm install --save-dev rollup-plugin-coffee-script' and ensure package.json has it.","cause":"Missing local installation or misspelled package name.","error":"Error: Cannot find module 'rollup-plugin-coffee-script'"},{"fix":"Use 'import coffee from 'rollup-plugin-coffee-script''.","cause":"Wrong import: named import instead of default import.","error":"TypeError: coffee is not a function"},{"fix":"Run 'npm install coffeescript@2' or add it to package.json.","cause":"Missing peer dependency coffeescript@2.x.","error":"Error: Could not resolve 'coffeescript' (peer dependency)"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}