Counselllor / Counsellor-Web

Counselling/Recommendation System for new Undergrad Students
http://counsellor.social/
MIT License
78 stars 173 forks source link

Add JOI schema validator to improve data validation #203

Open GeniusNirmit opened 1 year ago

GeniusNirmit commented 1 year ago

Problem: Currently, the system lacks a robust data validation mechanism, resulting in potential data inconsistencies and errors. This leads to difficulties in maintaining data integrity and can cause issues throughout the application.

Solution: Integrate JOI schema validator into the system to enhance data validation capabilities. JOI is a powerful validation library for JavaScript that provides a declarative way to define data validation rules. By incorporating JOI, we can easily define and enforce data validation rules, ensuring that data entered into the system meets the required criteria.

There are various other alternatives that are considered: 1.) Roll our own validation solution: Developing a custom validation solution would be time-consuming and error-prone. It would require significant effort to handle various validation scenarios effectively.

2.) Use other existing validation libraries: While there are other validation libraries available, JOI stands out due to its extensive features, flexibility, and widespread adoption. It provides a rich set of validation rules and allows for complex validations with ease.

Without a proper data validation mechanism, the system is prone to accepting invalid or inconsistent data. This can lead to issues such as corrupted data, application crashes, and incorrect processing. By adding a JOI schema validator, we can ensure that data entered into the system adheres to the defined validation rules, improving overall data quality and system reliability.

I am eager to formally contribute to this issue, utilizing my expertise and skills to provide valuable insights and potential solutions.

thestarsahil commented 1 year ago

Drop a your mail id ! I need a backend developer lead ! who can handle the data and all other stuff !

GeniusNirmit commented 1 year ago

nirmitrptp@gmail.com

Please let me know the further details...