paambaati / neon-js-sdk

TypeScript SDK for managing your Neon Serverless PostgreSQL projects
MIT License
17 stars 1 forks source link

export internal types #2

Closed tilman closed 1 year ago

tilman commented 1 year ago

Hey, all internal types aren't exportet. This makes it very hard to use this package since in many cases the developer would need to re-create the same type or copy-paste it from this repo.

See this code snippet which would need BranchCreateRequest:

    const createBranchConf: BranchCreateRequest = {
      "branch": {
        "name": "test-123",
      },
      "endpoints": [{
        "type": "read_write",
      }]
    };
    branch = await neonClient.branch.createProjectBranch(project.id, createBranchConf);

And also the return types can not get checked against GeneralError vs BranchResponse without the import of the types.

paambaati commented 1 year ago

:tada: This issue has been resolved in version 1.1.1 :tada:

The release is available on:

Your semantic-release bot :package::rocket:

tilman commented 1 year ago

Thanks for the quick response! Works fine now :)