Type window.nonce (#51200)

This commit is contained in:
Josh Hunt 2022-06-22 09:28:05 +01:00 committed by GitHub
parent 26f6b91fd9
commit 8fa951df04
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View File

@ -10,8 +10,8 @@ if (window.public_cdn_path) {
window.__grafana_public_path__ =
__webpack_public_path__.substring(0, __webpack_public_path__.lastIndexOf('build/')) || __webpack_public_path__;
if ((window as any).nonce) {
__webpack_nonce__ = (window as any).nonce;
if (window.nonce) {
__webpack_nonce__ = window.nonce;
}
// This is an indication to the window.onLoad failure check that the app bundle has loaded.

View File

@ -4,5 +4,6 @@ export declare global {
__grafana_public_path__: string;
__grafana_load_failed: () => void;
public_cdn_path: string;
nonce: string | undefined;
}
}