【发布时间】:2021-08-13 00:29:54
【问题描述】:
我需要在 Ionic Http native 的 get 请求的请求正文中发送一些数据。
我正在使用以下代码发送获取请求,但这会将数据转换为查询字符串。
this.http.get(
'apiendpoint',
data ,
headers
);
}
使用以下插件:
import { HTTP } from '@ionic-native/http/ngx';
以下是官方文档的链接:
【问题讨论】:
-
在这种情况下,您可以将数据发送到 post 方法而不是 get。 bcoz get 总是向 queryString 发送数据。
标签: ionic-framework ionic4 ionic-native