Luiz “Felds” Liscia
Luiz “Felds” Liscia
I'll take a look on the current state of those and report back back to you.
Sure!! Having a way to drop to lower level brings its own challenges, and trying to mix both approaches would be crazy. What if we added a whole different callback...
It seems like added complexity since (AFAIK), discord doesn't accept markup beyond a tiny subset of markdown, making template strings good enough. I think it's better keeping the lib focused...
That part is sorted out. My suggestion is just to change the typings to allow strings, so people don't need to use hacks like this to circumvent the requirement for...
Before using your library, I was passing everything as strings because the request is made using [form data](https://github.com/binance/binance-spot-api-docs/blob/master/rest-api.md#example-1-as-a-request-body) and every param is sent as string anyways (as opposed to JSON,...
(just as a clarification about my suggested type: I suggested `numberInString` because it's an [existing type](https://github.com/tiagosiebler/binance/blob/f7123b5499bafb82ba0d120d07838f1c56fbff40/src/types/shared.ts#L3) used widely on the project that resolves to `number | string`)
> I had hoped to eventually improve how types resolve so that typescript knows "this client was instanced with the beautifier enabled, so all numberInString fields are definitely number and...
Good new is that it seems possible with [conditional types](https://www.typescriptlang.org/docs/handbook/2/conditional-types.html): https://www.typescriptlang.org/play?#code/JYWwDg9gTgLgBDAnmApnA3nAogRwK4CGANgDTYAeqAxvAL5wBmUEIcA5AAJKoC0VAFsSIoAdgHMUAZwD0eGMCKS2AWABQa7mgBCKAnOANgKACYBhIkZHwAvBjgAjXfoaIAXAih40tDcjQAlAgB3c0sbO0c9eRd3BmJJb19UOFDRcJ0ogyMzCzS4AB84QJDcqzUktAA5PBBHKAB5KABlGChgcQAeABU4FHIYUWNJFNKYAD44Wx6+gZEhuAznbNSrOAB+OBEaurh3SVb2sXLVTTgqAgTh2wBtNTgKahgO3EIiDuralAbmg870SOcbg8XloYzIW0+UDGYLuDxQNGe+GI722X0aLTafwB0SBcUUKFBZH2mLE0JIagAukA
The type of the client can be inferred by the values in the constructor like this: https://www.typescriptlang.org/play?#code/C4TwDgpgBAQghgV2ASwGbIgEwApwE5wC2UJAvFAN5QBGEiKqIAXFMHgtAL4CwAUKJCgAlOAHdcBYiWnTyVWvTTMoqOABsAzlz4DoAYTUYAdsAlENMqOQAU8JGgw58RKAB9hYs4QCUUAGSUAPbAABYQeCwARGDOhBqRPLw64NAAcgiEtHgA8ngAymzIRgDmADwAKlAQAB7AEEaYFgbGprEaAHxWUJU1dQ0WdgyOXlAA-FBGGVlQLBqFJXx8mBAAxmr40GtwGk2G9cAVVbX1jVDN+14dlHwkK4FGc+wrwIF41jGSGizl3gDcN1BihBgAA1dQcazeFjpTLhXIFPBFMrldr-XiJPh3B7AKBrFoAQS6RggojOexM1goCnsjBYbA4ABooMEwhEoNE2glvJjycB8QA6IGg8EQSGLXhYua43kwIkksktSnUhjKVSaCBMlnhKIfcxcnktGCC4FgtQQ7m8IA (hover the `getValue()` calls to see the inferred types)
@tiagosiebler can you help me with this? the circleci tests are failing for something out of the scope of this change: ```txt ● Private Spot REST API Endpoints › Trade...