Building a robust backend on Google Apps Script requires moving beyond the built-in browser editor. For complex projects like the infrastructure powering Antinna, we need a modern development environment that enforces Clean Architecture and DRY principles. In this comprehensive guide, we will set up a professional workflow using TypeScript for type safety, esbuild for lightning-fast bundling, and clasp for automated deployment. 1. The Directory Structure A clean architecture begins with a clean file system. We strictly separate our source code ( src ) from the compiled output ( dist ). Note that the appsscript.json manifest must live in the dist folder. Project Directory Tree Text Copy antinna-backend/ ├── dist/ # Compiled output (pushed to Apps Script) │ ├── appsscript.json # Mandatory Google manifest file │ └── ...js files ├...
Adding progressive web app (PWA) features like background push notifications to a Google Blogger site has historically been an uphill battle. The core issue? Browsers demand that your background communication engine ( firebase-messaging-sw.js ) must live at the absolute root directory of your custom domain (e.g., yourdomain.com/firebase-messaging-sw.js ) to securely manage the site's network scope. Because Blogger is a completely managed platform, it lacks a traditional file directory system. You cannot simply upload a raw JavaScript file to your root path. If you try hosting it on an external CDN or storage bucket, the browser will instantly block it due to strict Service Worker cross-origin security protocols. The Architecture Strategy We bypass this platform limitation using Cloudflare Workers as an edge routing layer. By proxying your domain traffic through Cloudflare, we can intercept the exact path your service worker requires and dynamically inject ...