ebuyum asked
ebuyum replied
Tried adding ‘Access-Control-Allow-Origin’: ‘*’ to the request headers but didn’t seem to help
ebuyum replied
Checking online suggests using packages such as http-proxy-middleware, but its interesting that something changed during the versions
pranavxc replied
Update index.js
file inside the generated code to enable Cross origin access
```js
const cors = require(“cors”);
(async () => {
const app = require(‘express’)();
const {Noco} = require(“nocodb”);
app.use(
cors({
origin: “*”,
})
);
app.use(await Noco.init({}));
console.log(Visit : localhost:${process.env.PORT}/dashboard
)
app.listen(process.env.PORT);
})()
```
ebuyum replied
Ah, ok, interesting
let me try, since I’ve got nocodb deployed on a cloud foundry instance
ebuyum replied
I’m guessing the nocodb-seed project doesn’t get updated a lot?
I can just use a modified index.js file and still have latest nocodb right?
pranavxc replied