Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/harshkapadia2/cors
A simple demo of a few scenarios that use CORS.
https://github.com/harshkapadia2/cors
cors
Last synced: 3 days ago
JSON representation
A simple demo of a few scenarios that use CORS.
- Host: GitHub
- URL: https://github.com/harshkapadia2/cors
- Owner: HarshKapadia2
- License: mit
- Created: 2022-06-03T21:13:46.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2023-02-12T05:01:16.000Z (almost 2 years ago)
- Last Synced: 2024-10-11T11:27:15.863Z (2 months ago)
- Topics: cors
- Language: JavaScript
- Homepage:
- Size: 758 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# CORS
A simple demo of a few scenarios that use [Cross Origin Resource Sharing (CORS)](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS).
> This is a part of [my talk on CORS](https://talks.harshkapadia.me/cors).
## Usage
### Client Setup
- Serve `client/index.html` on port 3000 (`http://localhost:3000`).
- The [`serve` package](https://www.npmjs.com/package/serve) can be used.### Server Setup
- In `server` run `npm install` to install all dependencies.
- Run the server on port 5000 (`http://localhost:5000`) by running `npm run start` in the `server` directory.### Proxy Server Setup
- In `proxy-server` run `npm install` to install all dependencies.
- Run the server on port 8000 (`http://localhost:8000`) by running `npm run start` in the `proxy-server` directory.## Resources
- My talk on CORS: [talks.harshkapadia.me/cors](https://talks.harshkapadia.me/cors)
- My resources: [dev.harshkapadia.me/resources#cors](https://dev.harshkapadia.me/resources#cors)