The second code sample at https://pouchdb.com/gql.html reads:
const pouchdb;
PouchDB('idb://test', function(err, db) {
pouchdb = db;
// Use pouchdb to call further functions
db.gql({select: "*", where: "type='Fire' and name is not null"}, function(err, result){
if(!err){
// Use the results of the query here
}
}
})