Skip to content

MySQL.js bindings for Reason/Bucklescript

Notifications You must be signed in to change notification settings

davidgomes/bs-mysql

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MySQL.js Bindings for Reason/Bucklescript

This repository contains in-progress Reason/Bucklescript bindings for mysql.

Example

let conn = Mysql.createConnection(~host="127.0.0.1", ~port=3306, ~user="root", ());

Mysql.query(conn, "SHOW DATABASES", result => {
  switch (result) {
  | Ok(results) => Js.log(results.results)
  | Error(err) => Js.log(err##message)
  }
});

Mysql.endConnection(conn);

Installation

  1. Install the bindings using npm install --save bs-mysql
  2. Add the bindings to bsconfig.json:
{
  "bs-dependencies": ["bs-mysql"]
}

Build

npm run build

Build + Watch

npm run start

Current State & Todo

The API is still very incomplete. Use at your own risk, contributions are welcome!

About

MySQL.js bindings for Reason/Bucklescript

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages