Reputation: 221
(corsheaders.E014) Origin 'http://localhost:4200/' in CORS_ORIGIN_WHITELIST should not have path .Im getting this error.
CORS_ORIGIN_WHITELIST = ( 'http://localhost:4200/', )
Origin 'http://localhost:4200/' in CORS_ORIGIN_WHITELIST should not have path .Im getting this error.
Upvotes: 21
Views: 17830
Reputation: 711
Remove the slash (/
) from the end of the line (after the number 4200), leaving it as:
CORS_ORIGIN_WHITELIST = ( 'http://localhost:4200', )
That should make it work.
Upvotes: 71