eysk-io / course_reqs_api Goto Github PK
View Code? Open in Web Editor NEWAPI backend for the pre-requisite chain of specified courses at post-secondary institutions.
Home Page: https://www.api.course-reqs.com/
License: MIT License
API backend for the pre-requisite chain of specified courses at post-secondary institutions.
Home Page: https://www.api.course-reqs.com/
License: MIT License
Test spec files are very long. For example: src/utils/crud/__tests__/course.crud.spec.js
is 1849 lines. These could be broken down into individual methods.
The code
property for the course mode/schema is incorrect. Specifically, type: Number
should be type: String
.
Thus, instead of:
credits: {
type: Number,
required: true,
trim: true,
maxlength: 2
},
It should be:
credits: {
type: String,
required: true,
trim: true
},
Currently, the route parameters only work when the case matches what is inside of the database. For example, api/course/ubc
is incorrect while api/course/UBC
is correct. Instead, both should yield the same response.
As recommended
courses are not required, their requisites don't need to be propagated down to the lowest level like with hard pre-reqs.
Add a link to the documentation in the root.
Currently, the API does not include data for a course's title and description. These should be added for completeness of information.
Should be added to the school's schema. Currently only contains the school's name (and _id).
Refactor the entire application from JavaScript to strongly-typed TypeScript.
Change the api domain from www.course-reqs.com
to www.api.course-reqs.com
.
Then, remove /api
from the routes.
Currently, a pre-requisite course that doesn't exist in the database incorrectly returns more data than it should. For example, instead of responding only with the course's title, it will respond with an arbitrary number of credits
, and the school
that was used as the input parameter in the query. Instead, the only data should be the course's title
.
For example, the following response is incorrect:
{
"_id": "",
"preRequisites": [],
"coRequisites": [],
"equivalencies": [],
"subject": "",
"description": "",
"title": "Principles of Mathematics 12",
"code": -1,
"credits": 0,
"school": "UBC",
"__v":
}
This should instead be:
{
"_id": "",
"preRequisites": [],
"coRequisites": [],
"equivalencies": [],
"subject": "",
"description": "",
"title": "Principles of Mathematics 12",
"code": -1,
"credits": "",
"school": "",
"__v":
}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.