Skip to content

Force axios to use the http adapter instead of xhr #5263

@dysolix

Description

@dysolix

Is your feature request related to a problem? Please describe.

I am creating a library that will mostly be used in electron projects. The library needs to perform http request to a localhost server that uses a self signed certificate, so I need to use https.Agent. The problem is, that axios uses the xhr adapter instead of the http adapter. When i try to import the correct adapter from axios/lib/adapters/http I get the error ERR_PACKAGE_PATH_NOT_EXPORTED.

Describe the solution you'd like

I need a way to tell axios to always use the http adapter. The easiest way to do this is by exposing axios/lib/adapters/http.

Describe alternatives you've considered

No response

Additional context/Screenshots

No response

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