anttiviljami / react-openapi-client

Consume OpenAPI-enabled APIs with React Hooks
MIT License
57 stars 10 forks source link

Query: How to enable API to be hosted externally (CORS?) #17

Open stunney opened 3 years ago

stunney commented 3 years ago

Hello,

I want to break apart my API from my site into 3 parts:

1) https://mydomain.com (site that users visit)

2) https://aws.com/api/v1/blah

3) https://ipfs.com/myapidefinitionv1.json

What do I need to do with the client in order to accomplish this? It seems as though the client is expecting the API to be hosted by the same site/domain:port as the site that is using the API.

Thanks!