Skip to content

Schema and Type declaration support for ORM #36

@noppoMan

Description

@noppoMan

This is new function for building more typesafe app with npdynamodb.ORM.
Here is desired syntax.

var Chat = npdynamodb.define('chats', {
  npdynamodb: npd,

  schema: new Schema(function(s){
    s.string("id").hashKey();
    s.number("timestamp").rangeKey().default(s.fn.NOW);
    s.string("message");
    s.map("user", [s.String, s.Any]);
  })
});

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions