Skip to content
This repository has been archived by the owner on Mar 4, 2024. It is now read-only.

De-hardcode the HTTPS scheme to access the API URLs #697

Closed
programarivm opened this issue Jan 6, 2024 · 2 comments · Fixed by #698
Closed

De-hardcode the HTTPS scheme to access the API URLs #697

programarivm opened this issue Jan 6, 2024 · 2 comments · Fixed by #698
Assignees
Labels
good first issue Good for newcomers

Comments

@programarivm
Copy link
Member

The HTTPS scheme is being hardcoded throughout the code to access the API URLs as shown in the following example.

`https://${process.env.REACT_APP_API_HOST}:${process.env.REACT_APP_API_PORT}/api/autocomplete/event`

A new variable called REACT_APP_API_SCHEME needs to be created in the .env.example and .env files. Then, the API calls need to be updated accordingly.

`${process.env.REACT_APP_API_SCHEME}://${process.env.REACT_APP_API_HOST}:${process.env.REACT_APP_API_PORT}/api/autocomplete/event`

Happy coding and learning!

@programarivm programarivm added the good first issue Good for newcomers label Jan 6, 2024
@VTPrince
Copy link
Contributor

VTPrince commented Jan 6, 2024

Hi there, happy learning and coding!
@programarivm i'd love to work on this issue, could you assign it to me?

@programarivm
Copy link
Member Author

programarivm commented Jan 6, 2024

@VTPrince welcome to ChesslaBlab.

Thank you for joining the community, please make sure to read the Contributing Guidelines.

Happy learning!

programarivm added a commit that referenced this issue Jan 7, 2024
…-scheme-to-access-the-API-URLs

Added env variable for HTTPS support for API calls #697
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants