Skip to content
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

(Feature request) Should avoid generating inline <script> #27

Open
uschwarz opened this issue Apr 10, 2014 · 0 comments
Open

(Feature request) Should avoid generating inline <script> #27

uschwarz opened this issue Apr 10, 2014 · 0 comments

Comments

@uschwarz
Copy link

viewlets.L10nDatepicker writes an inline <script> into the head of the document. This will not work if somebody wants to enable Content-Security-Policy headers (or moves the JS files to the foot/asyncs them/defers them etc.).
Arguably, we can ship out the whole list of dateformats to the client, and the client can inspect lang attributes on body and/or html to pick the right language. Javascript to do that won't depend on the request, so it can be registered and cached by the JS Ressource Registry. The list of enabled languages is short for most people, so there's not much size overhead.

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

No branches or pull requests

1 participant