用express写过web应用的后台,但移动端应用没有url不知道该怎么弄了,比如
app.get('/a', function (req, res) {
res.send('Hello World!');
});
var server = app.listen(3000)
那我fetch 里的URL参数 填 fetch('http:127.0.0.1:3000/a',medthod:get) 这样吗?运行react-native run ios后发现并没有用
Copyright 2014-2025 https://www.php.cn/ All Rights Reserved | php.cn | 湘ICP备2023035733号
估计是跨域问题。
试试