0.0.12 • Published 5 years ago

@nutshelllab/dynamodb-table v0.0.12

Weekly downloads
25
License
MIT
Repository
github
Last release
5 years ago

dynamodb-table

Build Status npm bundle size Maintainability

Just sugar syntax over AWS DynamoDB

:warning: Work in progress, not published yet.

Install

yarn add @nutshelllab/dynamodb-table

Usage

Single primary key

import Table from '@nutshelllab/dynamodb-table'

const usersStore = new Table('users')

(async ({ id, ...data }) => {
  const users = await usersStore.put({
    key: { id },
    data
  })
})

Combined primary key

import Table from '@nutshelllab/dynamodb-table'

const postsStore = new Table('users_posts')

(async ({ userId, id, ...data }) => {
  const users = await usersStore.put({
    key: { userId, id },
    data
  })
})

API

method(arg1, arg2)

arg1

Type: string

Arg1 description

arg2

Type: Object

Arg2 description

License

MIT © Nutshell

0.0.12

5 years ago

0.0.11

5 years ago

0.0.10

6 years ago

0.0.9

6 years ago

0.0.8

6 years ago

0.0.7

6 years ago

0.0.6

6 years ago

0.0.5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.2

6 years ago

0.0.1

6 years ago