rx-sql
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

rx-sql

Build Status

RxJS Implementation of MySQL

import { RxSQL } from "rx-sql";
import { createConnection } from "mysql";
import { flatMap } from "rxjs/operators";
 
let db = createConnection({
  host: "localhost",
  database: "database",
  user: "root",
  password: "password"
});
 
let rxsql$ = new RxSQL(db);
 
rxsql$
  .query("SELECT * FROM table")
  .pipe(flatMap(result => result))
  .subscribe(
      result => console.log(result),
      error => console.error(error)
      () => console.info("Completed!")
      );

Package Sidebar

Install

npm i rx-sql

Weekly Downloads

3

Version

1.0.0

License

MIT

Unpacked Size

193 kB

Total Files

13

Last publish

Collaborators

  • inf3cti0n95