Skip to content

Cannot use TokenType.Aad since 0 is equal to false #31

@carlosedof

Description

@carlosedof

TokenType.Aad represents a 0 and this prop cannot be passed as a string.
0 when evaluated by JS is false.
Inside component implementation there is a function called getConfigFromProps that validates tokenType sent to the component, as it follows:
tokenType: tokenType || TokenType.Embed,
This always fails if left side of the expression is 0.

Maybe you could change Aad to 2 or allow to pass string as tokenType param.

Thanks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions