Henrik-3 / unofficial-valorant-api

Unofficial VALORANT API using the VALORANT Ingame API
424 stars 18 forks source link

index.d.ts lack of consturctor with token argument #69

Open eric2788 opened 9 months ago

eric2788 commented 9 months ago

I saw index.js has it but the declare module didn't.

adding constructor(token?: string); inside the export default class will fix the issue

image

image

using 2.3.1-stable.0

YpsilonTM commented 6 months ago

For some reason I can't even stop TS complaining even with adding the constructor

Henrik-3 commented 2 months ago

The current library is highly outdated, with some luck there will be a new one with API v4

YpsilonTM commented 2 months ago

I will be looking forward to it. I currently made my own simple wrapper for it on npmjs.org but an original from the API owner is always better 😄 ❤️

eric2788 commented 2 months ago

I will be looking forward to it. I currently made my own simple wrapper for it on npmjs.org but an original from the API owner is always better 😄 ❤️

I am using swagger-codegen

YpsilonTM commented 2 months ago

I am using swagger-codegen

it looks like it doesn't support TypeScript though :( or am I wrong?

eric2788 commented 2 months ago

I am using swagger-codegen

it looks like it doesn't support TypeScript though :( or am I wrong?

nah I was using typescript-fetch before:

image