Category "fetch"

Next.js, Strapi - Fetch response is empty

I have nextjs frontend that fetch data from strapi backend. Problem is that data is empty even if i can see on strapi dev logs that request has been made. This

401 unauthorized browser alert after fetch call with bearer token in react

I have a get fetch request with header having Bearer token, getting 401 unauthorized error, even if the response status condition checked in the then statement,

React - component doesn't re-render after delete request

I have problem that after deleting element from my list, component doesn't want to re-render. When I go through routing to some subpage and then back, item is a

fetch API always returns {"_U": 0, "_V": 0, "_W": null, "_X": null}

The below code always return the below wired object {"_U": 0, "_V": 0, "_W": null, "_X": null} as response. Here is my code getData = () => { f

Spring Security Rejects Fetch OPTIONS Preflight Outright If content-type = 'application/json'

If a Fetch POST to a Spring Security (v 5.6.1) enabled service endpoint sends this header: headers.append("Content-Type", "application/json"); the OPTIONS pref

Upload image to a nodeJs server using react-native

I want to upload an image from react-native (cli without expo) to a node server, i tried using axios with formData filed is not recognised by multer, then i tri

Javascript Fetch - Custom header is causing error: net::ERR_HTTP2_PROTOCOL_ERROR

Good day, I need to access the API of a payment gateway from my website. It is built with React and Next JS. While using the fetch method, I get an error: net::

React-Native multipart photo upload not working in android

I'm trying to send/upload image file to my back-end serve using fetch multipart upload in react-native, but fetch multipart form data upload is not working for

CORS access error for PUT method, api on aws hosted on elastic beanstalk

I've deployed an api on AWS API Gateway using http custom integration I've enabled CORS as seen below: (source: upload.cat) For both GET and PUT methods, I am g

HTTPS Request : CORS error but I still get data

I'm making HTTPS request to a private API (hosted Itop), I get an response but I get CORS Multiple Origin Not Allow error so my JavaScript program can't use the

How to fix the problem of react app not loading in Safari?

I built an application by using create-react-app, react-redux, react-router-dom, and material UI. The app uses Fetch API for http requests. It's working in Chro

Reactjs setState asynchronous

I am building a little search engine and got following problem: Everytime I enter a query, the last letter is missing. I figured out, that it has something to

How to get access to data in Github Repo with Nodejs Express

I'm currently trying to get COVID-19 from the Covid Data Repository by Johns Hopkins. https://github.com/CSSEGISandData/COVID-19 The repo get updated with new d

React Native / Expo : Fetch throws “Network request failed”

I saw several posts on the subject but without result. I have on the one hand a form which collects information (name, first name etc) then saves it in database

Post Form Using Fetch and Check Status OK

How does one get the reponse code when posting form data using fetch with vanilla JS, I have this code which posts but does not check response code with respons

movie-trailer npm isn't working properly in my netflix clone project

I've made a netflix clone using React.js, firebase, and have used TMDB api for movie database. I've also used react-youtube and movie-trailer npm. So it has thi

Fatal error: Uncaught Error: Call to undefined method mysqli_stmt::fetch_assoc() [duplicate]

i'm trying to learn mysqli. i get this error: Fatal error: Uncaught Error: Call to undefined method mysqli_stmt::fetch_assoc() in C:\xampp\h

REACT - Express : fetching data doesn't work on reload when user connected

I've deploy my first app using React with Nodejs/Express/MongoDB but I'm running through a bug I couldn't find any solution, so I'm coming here to find some hel

testing fastapi response to next.js with fetch, promise stuck in pending?

my fetch is stuck in pending when I query a fastapi endpoint in local dev. followed this blog and a few others - https://damaris-goebel.medium.com/promise-pendi

Flutter The argument type 'String' can't be assigned to the parameter type 'Map<String, dynamic>'

I got the problem when I want to fetch Data from PONS API. import 'package:eng_it_translator/model/model.dart'; import 'package:http/http.dart'; import 'dart:co