I connected the admin panel in the client import React from "react" import { Admin, Resource } from "react-admin" import restProvider from ‘ra-data-simple-rest’ import PostList from "./PostList"; const AdminPage = () => { return ( <Admin dataProvider={restProvider(‘http://192.168.88.83:3001′)} > <Resource name=’blogs’ list={PostList} /> </Admin> ); } export default AdminPage but the console shows an error admin#/blogs:1 […]
- Tags 'GET, 'http://localhost:3000'); res.setHeader('Access-Control-Allow-Methods', 'PUT', 'X-Requested-With'], although it is inside the same port, but the admin panel continues show error, content-type'); res.setHeader('Access-Control-Allow-Credentials', DELETE'); res.setHeader('Access-Control-Allow-Headers', for any requests on the project. Then in the server index.js I inserted this code app.use(function (req, I connected the admin panel in the client import React from "react" import { Admin, next) => { res.setHeader('Access-Control-Allow-Origin', OPTIONS, PATCH, post, res); }); }, Resource } from "react-admin" import restProvider from 'ra-data-simple-rest' import PostList from "./PostList"; const AdminPage = () => {, set the request's mode to 'no-cors' to fetch the resource with CORS disabled. fetch.js:39 GET 192.168.88.83:3001/blogs?filter=&range=%5, true); next(); }); And it helped