Q&A for FHIR in JS

Christian Ferreira 4/25/2018 2:57:49 PM

Post any questions or concerns you may have for the JavaScript starter project here! Be sure to subscribe for the latest updates.

0 Vote Up 0 Vote Down

3 Comment Details

Order By Standard | Newest | Votes | All
Chris 4/25/2018 5:29:14 PM

Does the call to the DHDR server need to be done on the backend. Would it be possible to do the call to the server on the front-end using AJAX?

0 Vote Up 0 Vote Down
Lee Van Buskirk 4/25/2018 5:41:29 PM

Hi Chris.

I've explored that option but it seems that it is not possible. The ajax call will fail the pre-flight request since the DHDR proxy server is expecting custom headers upon first contact. Since a) custom headers cannot be sent through a pre-flight request, b) web browsers must send a pre-flight, and c) the proxy server is expecting custom headers, sending a request through a client does not seem like a viable option. As a result, calling the DHDR server should be made through an application's backend.

1 Vote Up 0 Vote Down
Christian Ferreira 4/26/2018 2:47:05 PM

Note for developers using the JS template, ensure the project directory name is app.

Currently, it will not recognize other directories with other names. The set-up documentation has been updated to reflect this.

Last Edited 4/26/2018 2:59:28 PM

0 Vote Up 0 Vote Down

Stay Up To Date

Published four times a year, the Blueprint Bulletin provides readers with regular insight into the elements, services and new developments associated with the Ontario eHealth blueprint.