Nemo's Parental Misguidance

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

    0.0.18 • Public • Published

    Nubo

    Nubo is a platform for deploying and managing TypeScript applications.
    Visit nubo.app for more information.

    Getting Started

    First sign up for a free account at nubo.app, then install the Nubo client library with npm.

    npm i nubo
    # or
    yarn add nubo
    

    Usage

    import nubo from 'nubo';
    
    interface User {
      id: string;
      name: string;
      email: string;
      age: number;
    }
    
    const subscription = nubo.lists.subscribe<User>({
      list: 'users',
      apiKey: 'apik-xxxxx',
      options: {
        filter: { age: { $gt: 20 } },
        orderBy: {
          name: 'asc',
        },
        page: 1,
        pageSize: 25,
      },
      onUpdate: ({ items: users }) => {
        console.log(users);
      },
    });

    Authentication

    Authentication to your data is done with an API key. You have two options.

    Option 1

    Set the API key directly in the client.

    nubo.lists.subscribe<User>({
      apiKey: 'apik-xxxxx',
    });

    Option 2

    Set the API key with an environment variable. Choose one of the following, depending on your environment.

    NUBO_API_KEY=apik-xxxxx
    REACT_APP_NUBO_API_KEY=apik-xxxxx
    NEXT_PUBLIC_NUBO_API_KEY=apik-xxxxx
    

    Keywords

    none

    Install

    npm i nubo

    DownloadsWeekly Downloads

    4

    Version

    0.0.18

    License

    none

    Unpacked Size

    15.1 kB

    Total Files

    23

    Last publish

    Collaborators

    • nubodev