{"library":"egg-mysql","type":"library","category":null,"description":"MySQL plugin for the Egg.js framework, providing a convenient wrapper around @eggjs/rds (ali-rds). Version 5.0.0 requires Node >=18.0.0. It supports both single and multiple data sources, CRUD operations, and manual/automatic transaction management. The plugin extends the app and agent with mysql/mysqls instances, enabling straightforward SQL queries. Key differentiators: tight integration with Egg.js lifecycle, singleton pattern for multiple DB clients, and full TypeScript type definitions.","language":"javascript","status":"active","version":"5.0.0","tags":["javascript","egg","eggPlugin","egg-plugin","mysql","database","typescript"],"last_verified":"Fri Jun 05","install":[{"cmd":"npm install egg-mysql","imports":["// config/plugin.ts\nexport default { mysql: { enable: true, package: 'egg-mysql' } };","// config/config.default.ts\nexport default { mysql: { client: { host: 'localhost', port: '3306', user: 'root', password: 'pass', database: 'test' }, app: true } };","await app.mysql.query('SELECT * FROM users');"]},{"cmd":"yarn add egg-mysql","imports":[]},{"cmd":"pnpm add egg-mysql","imports":[]}],"homepage":"https://github.com/eggjs/egg-mysql#readme","github":"https://github.com/eggjs/egg-mysql","docs":null,"changelog":null,"pypi":null,"npm":"egg-mysql","openapi_spec":null,"status_page":null,"smithery":null,"compatibility":null}