OpenClassrooms-Student-Center / OpenClassrooms-Student-Center/P6JS
Documentation inconsistencies on API routes + Windows dev script issue
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 0
- Forks
- 28
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
While testing the API, I noticed several discrepancies between the documentation and the actual behavior of the endpoints, as well as a minor cross-platform issue with the dev script. Here are the details:
1. Login route
- Doc says :
POST /login
- Actually works :
POST /api/login
2. Profile image
- Doc says :
GET /api/profile-image
- Reality : this route doesn't exist.
Instead, the image path is provided in response of :
GET /api/user-info
3. Images access
- Doc says :
GET /uploads/<filename>
- Actually works :
GET /images/<filename>
4. Windows dev script issue
- The current
package.jsonscript uses :
"dev": "node_modules/.bin/nodemon app/index.js"
- Problem : On Windows, this path is not recognized, causing the dev server to fail.
- Fix : Use the cross-platform version :
"dev": "nodemon app/index.js"
Both npm and Yarn automatically include node_modules/.bin in the PATH when running scripts.
Would it be possible to update the documentation accordingly?
This would save students some time and confusion when working with the project.
Thanks!
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by comparing the API route documentation with the behavior described for app/index.js, then inspect package.json and its dev script. Update the documented login, profile-image, and image paths, and use the cross-platform dev command; done means the documentation matches the routes and the development script works on Windows.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- documentation, tooling
- Issue type
- Documentation
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100