Giter Site home page Giter Site logo

edgedb-deno's Introduction

EdgeDB Deno driver

deno land Build Status Join GitHub discussions

edgedb-deno is the official EdgeDB driver for Deno. ๐Ÿฆ•

This repo is automatically generated from the source of the edgedb-js driver. For documentation, issues, or details about the development of edgedb-deno, please refer to the edgedb-js repo.

Import

import * as edgedb from "https://deno.land/x/edgedb/mod.ts";

Following Deno convention it is recommended to always import a specific tagged version of edgedb-deno, and to not import from the underscored /_src path (all of edgedb-deno's public API is exported from the /mod.ts file).

The main branch of this repo mirrors the latest commits to the master branch of edgedb-js, though it not recommended to import from this branch directly, as it may contain breaking changes.

Quick start

First install EdgeDB, then create and start an EdgeDB instance. The tutorial in the EdgeDB docs is a good place to get started: https://www.edgedb.com/docs/tutorial/index/

Now you're ready to import edgedb-deno and start querying your database:

import * as edgedb from "https://deno.land/x/edgedb/mod.ts";

const conn = await edgedb.connect("tutorial");

console.log(await conn.queryOne("SELECT 1 + <int64>$num", { num: 2 }));

await conn.close();

For the full documentation see the edgedb-js docs.

Permissions

The permissions edgedb-deno may require are detailed below:

--allow-net (required)

This permission is required to connect to EdgeDB instances.

--allow-env (optional)

Needed if connecting with an instance name, to get your home directory (where the .edgedb directory is located).

--allow-read (optional)

Needed if connecting with an instance name, to read the instance credentials file from <home-dir>/.edgedb/credentials.

--unstable flag

edgedb-deno supports connecting to an EdgeDB instance via a unix socket file, however this currently requires using the --unstable flag, and the --allow-read and --allow-write permissions for the socket file.

edgedb-deno's People

Contributors

1st1 avatar edgedb-ci avatar jaclarke avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.