2021-04-07 12:33:16 +02:00
|
|
|
const PouchDB = require("pouchdb")
|
2021-04-14 15:13:48 +02:00
|
|
|
const env = require("../environment")
|
2021-04-07 12:33:16 +02:00
|
|
|
|
|
|
|
// level option is purely for testing (development)
|
|
|
|
const COUCH_DB_URL =
|
2021-04-14 15:13:48 +02:00
|
|
|
env.COUCH_DB_URL || "http://budibase:budibase@localhost:10000/db/"
|
2021-04-07 12:33:16 +02:00
|
|
|
|
|
|
|
const Pouch = PouchDB.defaults({
|
|
|
|
prefix: COUCH_DB_URL,
|
|
|
|
})
|
|
|
|
|
|
|
|
module.exports = Pouch
|