Created
January 18, 2016 08:01
-
-
Save n1k0/6f925c655798b9a1abeb to your computer and use it in GitHub Desktop.
Firefox service worker bug with ZERO WIDTH JOINER char (0x200D)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html><meta charset="utf-8"></head> | |
<body> | |
<script> | |
window.navigator.serviceWorker.register("worker.js", {scope: "/"}) | |
.then(reg => console.log("registered", reg)) | |
.catch(err => console.error("service worker error", err)) | |
</script> | |
</body> | |
</html> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// a contains a ZERO WIDTH JOINER (0x200D) | |
var a = ""; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment