{"id":26784,"library":"babel-plugin-zova-bean-use","title":"Zova Bean Use Babel Plugin","description":"A Babel plugin (v1.1.8) specific to the Zova framework that transforms bean usage in JavaScript/TypeScript projects. It enables the '@beanUse' decorator pattern to inject dependencies or services. This plugin targets a niche Zova ecosystem and has low release cadence. It is not suitable outside Zova. Other IOC or DI Babel plugins like babel-plugin-transform-decorators may serve broader needs.","status":"active","version":"1.1.8","language":"javascript","source_language":"en","source_url":null,"tags":["javascript","framework","zova"],"install":[{"cmd":"npm install babel-plugin-zova-bean-use","lang":"bash","label":"npm"},{"cmd":"yarn add babel-plugin-zova-bean-use","lang":"bash","label":"yarn"},{"cmd":"pnpm add babel-plugin-zova-bean-use","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Peer dependency for Babel plugin interface","package":"@babel/core","optional":false}],"imports":[{"note":"This package does not export an ES module. Use require() in .babelrc or programmatic config.","wrong":"import plugin from 'babel-plugin-zova-bean-use';","symbol":"default","correct":"module.exports = require('babel-plugin-zova-bean-use');"},{"note":"Full plugin name required in babel config.","wrong":"plugins: ['bean-use']","symbol":"babel-plugin-zova-bean-use","correct":"plugins: ['babel-plugin-zova-bean-use']"},{"note":"Options must be in nested array syntax.","wrong":"plugins: ['babel-plugin-zova-bean-use', { option: true }]","symbol":"babel-plugin-zova-bean-use with config","correct":"plugins: [['babel-plugin-zova-bean-use', { option: true }]]"}],"quickstart":{"code":"module.exports = {\n  presets: [\n    ['@babel/preset-env', { targets: { node: 'current' } }],\n  ],\n  plugins: ['babel-plugin-zova-bean-use']\n};\n\n// Then in your code:\nclass MyClass {\n  @beanUse MyService;\n  // ...\n}","lang":"javascript","description":"Shows how to add the plugin to Babel config for transforming the @beanUse decorator in classes."},"warnings":[{"fix":"Ensure your project is a Zova application.","message":"Plugin only works within Zova framework context; using it elsewhere may break builds.","severity":"gotcha","affected_versions":"all"},{"fix":"Upgrade to Babel 7+.","message":"Requires Babylon 7+ (Babel 7). Not compatible with Babel 6.","severity":"breaking","affected_versions":">=1.0.0"},{"fix":"Contact Zova maintainers for current approach.","message":"Plugin is specific to an early version of Zova; may not be maintained.","severity":"deprecated","affected_versions":">=1.0.0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"Use `require('babel-plugin-zova-bean-use')` instead of `import`.","cause":"Using ES module import syntax with this plugin which expects CommonJS.","error":"ReferenceError: exports is not defined"},{"fix":"Run `npm install --save-dev babel-plugin-zova-bean-use` and use full name in plugins.","cause":"Plugin not installed, or incorrect package name in config.","error":"Error: Cannot find module 'babel-plugin-zova-bean-use'"},{"fix":"Add '@babel/plugin-proposal-decorators' before this plugin.","cause":"Decorators not enabled in Babel config.","error":"SyntaxError: Support for the experimental syntax '@' isn't currently enabled"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}