Skip to content

ESLint no-named-as-default-member for isAxiosError #5164

Closed

Description

@rlesniak

Describe the bug

After upgrade to 1.1.3 my ESLint complains about import/no-named-as-default-member

image

But in reality, I cannot import as import { isAxiosError } from 'axios';

image

So something is broken with TS types

To Reproduce

Turn on import/no-named-as-default-member ESLint rule, update axios to 1.1.3, try to use axios.isAxiosError and observe error.

Code snippet

No response

Expected behavior

I should be able to satisfy eslint and be able to import as import { isAxiosError } from 'axios';

Axios Version

1.1.3

Adapter Version

No response

Browser

No response

Browser Version

No response

Node.js Version

No response

OS

No response

Additional Library Versions

xo 0.52.4

Additional context/Screenshots

No response

Activity

  1. codedeeply commented on Oct 20, 2022

    @codedeeply

    Running into this behavior as well after upgrading to 1.1.3.

  2. arash-bizcover commented on Oct 24, 2022

    @arash-bizcover

    Me too had to Go back to v 1.1.0
    did lots of swears as well

  3. dd3vahmad commented on Aug 6, 2024

    @dd3vahmad

    Ran into this error also but all i just did was to set the error to the universal type "any" and that fix it for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions