CORS Essentials
上QQ阅读APP看书,第一时间看更新

Chapter 1. Why You Need CORS

In this chapter, you will learn about the following:

  • The same-origin policy that limits sharing resources across domains
  • Granting access to CORS requests by setting headers
  • How to do something with the responseText request from a CORS request
  • Rudimentary security in CORS and ways to add more security
  • Preflight requests to prepare for some types of CORS methods and events
  • Enabling the crossorigin attribute in a script tag for better troubleshooting
  • Alternatives to CORS: JSON-P, WebSockets, and window.postMessage