Skip to content

Latest commit

 

History

History
 
 

typescript

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 

TypeScript Example

👋 This example demonstrates connecting to an instance of GlareDB and running an example query in TypeScript using Node.js. Since GlareDB is postgres-compatible, familiar tools are used:

Running

The example requires:

  • running glaredb locally in server mode:

    # change to a directory you'd like glaredb installed into
    cd ~
    curl https://glaredb.com/install.sh | sh
    ./glaredb server
  • having Node.js installed and running yarn start:

    # from the repository root
    cd examples/typescript
    yarn install
    yarn start

Make sure to replace the placeholder connection string in example.ts with the appropriate configuration for your GlareDB instance.

For more information on installing glaredb locally, see: Trying GlareDB locally. For more information on our cloud offering, see: Getting Started.