Skip to content

augment arc.tables to lazily load index schema(s) #370

Description

@reconbot

I want to have some sort of runtime validation for my use of indexes. I can do a describe table but I think arc/functions might be an interesting place to do the discovery like it does for tables.

The index name and fields would be nice.

const tables = await arc.tables()
const tableName = tables.name('users')
const indexes = tables.indexes('users)
// { "email-index": { hash: 'email', sort: 'createdAt' } }

I'm not sure I nailed the result object but it's close.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions