{"id":22120,"library":"rollup-plugin-lux","title":"rollup-plugin-lux","description":"A Rollup plugin that ensures constructor.name remains correct after bundling Lux applications. Version 3.0.0 is the current stable release. It appends an Object.defineProperty call below each constructor that extends a Lux base class to preserve the class name, which would otherwise be lost due to Rollup's module bundling. This plugin is intended for internal use by the Lux framework and is not required for typical Lux users.","status":"active","version":"3.0.0","language":"javascript","source_language":"en","source_url":null,"tags":["javascript"],"install":[{"cmd":"npm install rollup-plugin-lux","lang":"bash","label":"npm"},{"cmd":"yarn add rollup-plugin-lux","lang":"bash","label":"yarn"},{"cmd":"pnpm add rollup-plugin-lux","lang":"bash","label":"pnpm"}],"dependencies":[],"imports":[{"note":"ESM-only; named exports are not provided.","wrong":"const luxPlugin = require('rollup-plugin-lux')","symbol":"default","correct":"import luxPlugin from 'rollup-plugin-lux'"},{"note":"The plugin is the default export.","symbol":"luxPlugin","correct":"import luxPlugin from 'rollup-plugin-lux'"}],"quickstart":{"code":"// rollup.config.js\nimport luxPlugin from 'rollup-plugin-lux';\n\nexport default {\n  input: 'src/index.js',\n  output: {\n    file: 'dist/bundle.js',\n    format: 'cjs'\n  },\n  plugins: [\n    luxPlugin()\n  ]\n};","lang":"javascript","description":"Example Rollup configuration using the Lux plugin to preserve class names in bundled output."},"warnings":[{"fix":"Ensure classes that need name preservation extend from a Lux class.","message":"Only works with classes that extend Lux base classes (e.g., Model, Controller). Custom classes without Lux superclass are unaffected.","severity":"gotcha","affected_versions":">=1.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 rollup-plugin-lux --save-dev","cause":"Package not installed or not in node_modules.","error":"Error: Cannot find module 'rollup-plugin-lux'"},{"fix":"Use import luxPlugin from 'rollup-plugin-lux'","cause":"Incorrect import style: using require() instead of default import.","error":"TypeError: luxPlugin is not a function"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}