Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

interface desatualizada #23

Closed
coelho-faminto opened this issue May 5, 2023 · 1 comment
Closed

interface desatualizada #23

coelho-faminto opened this issue May 5, 2023 · 1 comment

Comments

@coelho-faminto
Copy link

type FetchPayloadParams = {

esta interface nao deve ser usada como esta, o correto seria utilizar o codigo importado de dynamicPayload =>

// PIXFetchParams adicionado na linha abaixo
import { PIXFetchResults, PIXFetchParams } from '../dynamicPayload';
import { PixDynamicObject, PixStaticObject } from './pixElements';
import { PixError } from './pixError';
export interface PixFnDefault {
    readonly toBRCode: () => string;
    readonly toImage: () => Promise<string>;
}
export interface PixStaticFn extends PixFnDefault {
    readonly throwIfError: () => PixStaticObject;
}

export interface PixDynamicFn extends PixFnDefault {
    // trocado abaixo por PIXFetchParams
    readonly fetchPayload: (params: PIXFetchParams) => Promise<PIXFetchResults | PixError>;
    readonly throwIfError: () => PixDynamicObject;
}
export {};
@thalesog
Copy link
Owner

@coelho-faminto sinta-se a vontade para encaminhar um PR com sugestões, obrigado.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants