Skip to content

Instantly share code, notes, and snippets.

View danielrozenberg's full-sized avatar
💭
🐈

Daniel Rozenberg danielrozenberg

💭
🐈
View GitHub Profile
@danielrozenberg
danielrozenberg / userContent.css
Created July 26, 2020 06:11
Add this to your Firefox profile (under .../profile-directory/chrome) to justify the text in Reader View
.moz-reader-content p {
text-align: justify;
}
@danielrozenberg
danielrozenberg / patch.patch
Created August 22, 2018 19:55
Rewrite the AMP runtime library so that extensions loaded by the Shadow embed code will be loaded from localhost, not from the CDN
diff --git a/src/service/extensions-impl.js b/src/service/extensions-impl.js
index e6116b8ec..d40ea8ad8 100644
--- a/src/service/extensions-impl.js
+++ b/src/service/extensions-impl.js
@@ -556,6 +556,7 @@ export class Extensions {
if (this.isExtensionScriptRequired_(extensionId, holder)) {
const scriptElement =
this.createExtensionScript_(extensionId, opt_extensionVersion);
+ scriptElement.src = scriptElement.src.replace(/https:\/\/cdn.ampproject.org\/rtv\/\d+\//, 'http://localhost:8000/dist/');
this.win.document.head.appendChild(scriptElement);

Keybase proof

I hereby claim:

  • I am danielrozenberg on github.
  • I am danielrozenberg (https://keybase.io/danielrozenberg) on keybase.
  • I have a public key ASDPxR21PioU1DurX-S41wfDfL1mRHvH7QLEhSckHfOKJQo

To claim this, I am signing this object: