Skip to content

[v2] Make inline docs scripts external #9594

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jul 17, 2025
Merged

Conversation

aemous
Copy link
Contributor

@aemous aemous commented Jul 15, 2025

Context:

This change is in preparation for adding a Content-Security-Policy header to the AWS CLI API Reference versioned docs. The added header will block the loading of inline-scripts. To avoid breaking inline scripts on older versions of the docs, the header will allowlist these inline scripts. To avoid needing to update the header each time we modify these scripts in the future, we should move them to an external file.

Description of changes:

  • Replaced use of inline scripts with external script files.

Description of tests:

  • Ran make all on the docs, and verified the scripts are being loaded.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@aemous aemous requested a review from a team July 15, 2025 14:23
Copy link
Member

@kdaily kdaily left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Do we need to include this commit (0bbf4e2)? Looks like the changes it introduced were undone in the later commit.

@aemous
Copy link
Contributor Author

aemous commented Jul 15, 2025

Looks good. Do we need to include this commit (0bbf4e2)? Looks like the changes it introduced were undone in the later commit.

@kdaily The index.html file is from build, I accidentally included it in the PR, that commit is to remove the unintended file. The end result is as expected (index.html should not be committed).

@aemous aemous merged commit 7d41d90 into aws:v2 Jul 17, 2025
59 of 60 checks passed
@aemous aemous deleted the docs-externalize-scripts branch July 17, 2025 17:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants