Comments (4)
@umar-ahmed I think the purpose of us creating a mock is so that the frontend them doesn't even need any working API to work on anything. The mock is intended to be used at the frontend directly like so:
function getFormByID(id: string): Mode.SDCForm {
return mock.buildFormComplete()
}
Maybe to guarantee the correct handling of the API, the same function with the exact signature will be created in a mock client on the backend side for testing purposes. At the end of the day, when the backend team got the API up and running and tested, the frontend team can simply copy real implementation (getFormByID) from the backend mock to the frontend
from proj-dateam.
That will work, but I (and the prof) foresee issues with integration if we too heavily rely on just having the mock there on the frontend and not calling an API endpoint. "Integrate often, and integrate early" is the slogan that was instilled in me and I think that applies here.
If I'm not mistaken, we already have some scaffolding set up for the HTTP handlers (I think @vermaarn set it up?), so like you said, this task is just a matter of returning the mock for that handler.
from proj-dateam.
Blocked by #51
from proj-dateam.
Completed by #67
from proj-dateam.
Related Issues (20)
- Create a new patient prior to creation of a response on frontend HOT 1
- Add timestamps (updatedAt, createdAt) for form and response models
- Create a new page called Patients that lists out all the patients in our system and allows you to create a new one
- Implement SDCSection Parser HOT 1
- Implement SDCDisplayItem Parser HOT 1
- Add CI workflow to run tests on shared module
- Update all create APIs to return UID
- Call FormResponse validation on post responses at backend
- Add new endpoints to OpenAPI spec
- Enable and fix/update API unit tests HOT 1
- Create a new page for viewing a read-only version of a form response
- Move responses routes to `/responses/manage/...`
- Add patient selection combobox to top of form response
- Add dropdown menu to form response header
- Implement "Copy to clipboard" functionality for read-only form response URL
- Implement `PUT /responses/<id>` to allow replacing existing response
- Implemented `DELETE /responses/<id>` endpoint to allow deletion of form responses
- Create a new page called Procedures that lists out all the procedures in our system and allows you to create new ones
- Add search API
- Complete TextFieldTypeMeta
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from proj-dateam.