MySQL Driver

The MySQL driver lets you configure Nymph to query and save data to a MySQL database.

Installation

npm install --save @nymphjs/driver-mysql

Usage

Supply an instance of this driver with its configuration to Nymph's constructor.

import { Nymph } from '@nymphjs/nymph';
import MySQLDriver from '@nymphjs/driver-mysql';

const mysqlConfig = {
  host: 'your_db_host',
  database: 'your_database',
  user: 'your_user',
  password: 'your_password',
};

const nymph = new Nymph({}, new MySQLDriver(mysqlConfig));

// All done. Nymph is ready to use.

Options

See the config declaration file.