<code>pip install django-<a href="https://www.gaodaima.com/tag/cors" title="查看更多关于cors的文章" target="_blank">cors</a>-headers </code>
www#gaodaima.com来源gaodai$ma#com搞$代*码*网搞代码
- 将corsheaders 添加到INSTALLED_APPS
- 设置 MIDDLEWARE
*添加
<code>CORS_ORIGIN_ALLOW_ALL = True </code>