mirror of
https://github.com/niklasvh/html2canvas.git
synced 2023-08-10 21:13:10 +03:00
Update serialize-doctype.ts
This commit is contained in:
parent
a6fee57c11
commit
b119e2a5e2
@ -38,7 +38,8 @@ const createDocType = (doctype?: DocumentType | null): string => {
|
|||||||
let doctypePolicy: TrustedTypePolicy;
|
let doctypePolicy: TrustedTypePolicy;
|
||||||
if ((window as any).trustedTypes) {
|
if ((window as any).trustedTypes) {
|
||||||
doctypePolicy = (window as any).trustedTypes.createPolicy('html2canvas', {
|
doctypePolicy = (window as any).trustedTypes.createPolicy('html2canvas', {
|
||||||
createHTML: (ignored: string, doctype?: DocumentType | null): TrustedHTML => {
|
// @ts-ignore
|
||||||
|
createHTML: (ignored: string, doctype?: DocumentType | null): string => {
|
||||||
return createDocType(doctype);
|
return createDocType(doctype);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user