How can I specify the API pathname for different pages in my project?
This is the folder structure I am working with:
src
├── component
│ ├── common
│ └── layout
│
│
│
├── pages
│ ├── todo
│ │ ├── index.js
│ │ ├── list
│ │ ├── index.js
│ │
│ ├── counter
│
├── api
│ ├── user
│ ├── list
│
I would like to set up API calls like this: "localhost:3000/todo/api/..." or "localhost:3000/counter/api/..." instead of "localhost:3000/api/todo"
If you have any suggestions or guidance on how to achieve this, I would greatly appreciate it!