New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

axios-interface

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

axios-interface - npm Package Versions

1

1.4.2

Diff

dancerphil
published 1.4.1 •

dancerphil
published 1.4.0 •

Changelog

Source

1.4.0

  • 在没有传入 onPending 的情况下,DELETE 中的参数将被处理为 url params 而非 body,如:

    interface ParamsDeleteUser {
        id: number;
        token?: string;
    }
    
    const apiDeleteUser = createInterface<ParamsDeleteUser>('DELETE', '/users/{id}');
    
    apiDeleteUser({id: 1, token: 'abc'}); // 将被处理为  DELETE /users/1?token=abc
    
    // 如需 body,可以声明 transformDeleteParamsIntoBody,在 createFacroty、createInterface、request 阶段进行配置(在 1.4.x 推出)
    const options = {
        // ...others
        transformDeleteParamsIntoBody: true,
    };
    

    此变更对已经声明了 onPending 的方法无影响。

dancerphil
published 1.3.2 •

dancerphil
published 1.3.1 •

dancerphil
published 1.3.0 •

dancerphil
published 1.2.3 •

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc