Currently, json-server is being used to make local development based on API communication. The goal is to understand how to "deploy" or access this data from anywhere to prevent issues on the deployed site in the future
Tasks
[x] Deploy JSON file to a prod environment
[x] Test "Destinations" page behavior
[x] Address error scenario where the data is not accessible
Notes
Currently, an error is showing on Chromatic and mobile when deploying the site and using the --host option. This should be fixed to prevent ugly errors in both cases.
By creating a backend project, it is a good idea to handle routing from the server to avoid using the hash.
As the data will not change periodically, it will be helpful to implement a basic cache strategy or conditional fetching.
According to this thread, the only solution for running a JSON server is by downgrading the package to a specific version such as the @0.17.1. Reference: https://github.com/typicode/json-server/issues/1500
Description
Currently,
json-server
is being used to make local development based on API communication. The goal is to understand how to "deploy" or access this data from anywhere to prevent issues on the deployed site in the futureTasks
Notes
--host
option. This should be fixed to prevent ugly errors in both cases.