Skip to content

Commit cc3bc97

Browse files
committed
fix(loadScript): don't URI-encode src when searching for existing script
1 parent 26ada78 commit cc3bc97

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/loadScript.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ const loadScript = ({ src, ...props }: Props): Promise<void> =>
1313
return
1414
}
1515
if (typeof document.querySelector === 'function') {
16-
if (document.querySelector(`script[src="${encodeURIComponent(src)}"]`)) {
16+
if (document.querySelector(`script[src="${src}"]`)) {
1717
resolve()
1818
return
1919
}

0 commit comments

Comments
 (0)