Skip to content

Commit

Permalink
docs: relax CO headers for schemas (#1243)
Browse files Browse the repository at this point in the history
See title. This just allows frontend apps to pull schemas instead of
getting blocked by the CO policy.

EDIT:

Tested in the netlify preview and works as expected. Only the `schemas`
path is impacted, no CORS on rest of site.

Signed-off-by: Todd Baert <[email protected]>
  • Loading branch information
toddbaert authored Mar 9, 2024
1 parent b06a503 commit c7a7341
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions netlify.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,9 @@
poetry install -v &&
mkdocs build
"""

[[headers]]
# Relax cross origin restrictions for schemas, so they can be requested by front-end apps.
for = "/schema/*"
[headers.values]
Access-Control-Allow-Origin = "*"

0 comments on commit c7a7341

Please sign in to comment.