Hi, new to payload cms here. Created a new payload web application and got it up and running with my MongoDB atlas server. However, when i try to access localhost:3000, it says that safari cannot connect to server. Also, when i created a new study.ts under collections, it does not update in the admin panel no matter how many times i refresh the terminal. Tried to check if any other application is using port 3000, nope. Firewall is off. Checked the browser cache.
As a last resort, i created multiple servers and repos over the past 2 weeks to try to run it again, but always showing up with the same issue. Am i missing something here?
As for the safari issue I am not sure. But for the Study collection, you need to import it in your payload.config.ts file and add it to the collections array with the rest of your collections
I have already imported it in my payload.config.ts file and added to collections array. From my understanding, when i type yarn generate:type, the payload-types.ts file should be automatically updated with the studies:Study; under export interface config right? but in my case it does not work. i tried restarting everything and it doesnt change.
Yes that is the command and that is what you should expect. I would ensure you have saved the config file, then close your generated types file, run the command and re-open the types file
thank you so much for the help! I tried it and it did work. For the safari issue, i'll continue to look into it. If anyone have been facing the same issue and solved it, please share the solution here 🙂
Star
Discord
online
Get help straight from the Payload team with an Enterprise License.