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

Fix: Handle numeric enum from OpenAPI spec #169

Merged
merged 1 commit into from
Nov 12, 2021
Merged

Fix: Handle numeric enum from OpenAPI spec #169

merged 1 commit into from
Nov 12, 2021

Conversation

ashnewport
Copy link
Contributor

Fixes #45

Actual code change is on lines 404-405.

Open API spec with:

...
    "ExStatus": {
        "enum": [
          0,
          1,
          2
        ],
        "type": "integer",
        "format": "int32"
      },
...

should now output as:

export type ExStatus = 0 | 1 | 2;

Additional changes are from Husky hooks to format code.

@jonkoops jonkoops merged commit 10181d4 into oazapfts:master Nov 12, 2021
@jonkoops
Copy link
Collaborator

Thanks @ashnewport!

@ecrofeg
Copy link

ecrofeg commented Feb 9, 2022

Hi there! Guys, what about the release of this fix? RTKQ is suffering from this so much :(

reduxjs/redux-toolkit#1788

@nickwang0808
Copy link

Hi guys, are we releasing this soon? Really need this for RTKQ as well.

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

Successfully merging this pull request may close these issues.

s.replace is not a function
4 participants