- Go to
/main-domain
and runnpm install && npm run dev:watch
- Go to
/subdomain-01
and runnpm install && npm run dev:watch
- Go to
/subdomain-02
and runnpm install && npm run dev:watch
- Remember to mention
auth.application.com
,api.main.application.com
,api.reseller.application.com
pointed to127.0.0.1
in yourhosts
file - Visit
auth.application.com:3000
in your browser and hit submit button - Check the cookies in the browser
- Now goto other two servers i.e.
api.reseller.application.com:3001
andapi.main.application.com:3002
and check the cookies in developer console
mwaqar666/express-cross-domain-cookies
Test Project to check the behaviour of setting cookies in sub-domains of an application from single server response
TypeScript