Skip to content

Allow passing in a generic type for the client #76

Description

@razor-x
  • Consumers who use seam.client would like to use https://www.npmjs.com/package/typed-axios-instance
  • Supporting typed-axios-instance directly in this library is out of scope.
  • Instead, the SeamHttp class could provide setting the client type via 'fromClient`, e.g.,
import{SeamHttp}from'@seamapi/http'importtype{TypedAxios}from'typed-axios-instance'importtype{Routes}from'./routes.js'constseam=newSeam()// create a new instance normallytypeClient=TypedAxios<Routes>constseamWithTypedRoutes=Seam.fromClient<Client>(seam.client)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions