<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Javascript - Tag - Botmonster Tech</title><link>https://botmonster.com/tags/javascript/</link><description>Javascript - Tag - Botmonster Tech</description><generator>Hugo -- gohugo.io</generator><language>en</language><lastBuildDate>Sun, 05 Apr 2026 00:00:00 +0000</lastBuildDate><atom:link href="https://botmonster.com/tags/javascript/" rel="self" type="application/rss+xml"/><item><title>How to Use Service Workers for Caching on Static Sites</title><link>https://botmonster.com/posts/service-workers-deep-dive-caching-strategies-static-sites/</link><pubDate>Sun, 05 Apr 2026 00:00:00 +0000</pubDate><author>Botmonster</author><guid>https://botmonster.com/posts/service-workers-deep-dive-caching-strategies-static-sites/</guid><description><![CDATA[<div class="featured-image">
                <img src="/service-workers-deep-dive-caching-strategies-static-sites.png" referrerpolicy="no-referrer">
            </div><p>Service workers give you a programmable network proxy right inside the browser. They sit between your page and the server, intercept every fetch request, and let you decide whether to serve a response from cache or from the network. For static sites - where every page is a pre-built file and every asset has a predictable URL - this is a natural fit. A well-configured service worker makes your static site load in single-digit milliseconds on repeat visits, work fully offline, and pass every Lighthouse PWA audit. The entire implementation fits in a single JavaScript file under 100 lines.</p>]]></description></item><item><title>CSS Container Queries: Build Truly Responsive Components</title><link>https://botmonster.com/posts/container-queries-css-build-truly-responsive-components/</link><pubDate>Thu, 19 Mar 2026 00:00:00 +0000</pubDate><author>Botmonster</author><guid>https://botmonster.com/posts/container-queries-css-build-truly-responsive-components/</guid><description><![CDATA[<div class="featured-image">
                <img src="/container-queries-css-build-truly-responsive-components.png" referrerpolicy="no-referrer">
            </div><p>CSS <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/Guides/Containment/Container_queries" target="_blank" rel="noopener noreferrer ">container queries</a>
 (<code>@container</code>) style components based on the width of their parent container instead of the browser viewport. Add <code>container-type: inline-size</code> to a parent element, write <code>@container (min-width: 400px) { ... }</code> rules on the children, and those children automatically adapt their layout based on the space available to them - not the screen size. All major browsers have supported container queries since early 2023 (Chrome 105+, Firefox 110+, Safari 16+), and as of 2026 they sit at over 96% global support according to <a href="https://caniuse.com/css-container-queries" target="_blank" rel="noopener noreferrer ">Can I Use</a>
.</p>]]></description></item><item><title>Building a Progressive Web App from Scratch with Vanilla JavaScript</title><link>https://botmonster.com/posts/build-progressive-web-app-scratch-vanilla-javascript/</link><pubDate>Thu, 05 Mar 2026 00:00:00 +0000</pubDate><author>Botmonster</author><guid>https://botmonster.com/posts/build-progressive-web-app-scratch-vanilla-javascript/</guid><description><![CDATA[<div class="featured-image">
                <img src="/build-progressive-web-app-scratch-vanilla-javascript.png" referrerpolicy="no-referrer">
            </div><p>A Progressive Web App requires just three things beyond your existing website: a Web App Manifest JSON file that defines the app&rsquo;s name, icons, and display mode; a service worker that intercepts network requests for offline support and caching; and HTTPS hosting. Add these to any site with plain JavaScript - no React, Angular, or framework needed - and browsers will offer an install prompt, enable push notifications, and cache your app for offline use. The entire setup can be done in under an hour with three files.</p>]]></description></item><item><title>Core Web Vitals: How to Fix LCP, CLS, and INP</title><link>https://botmonster.com/posts/optimize-core-web-vitals-lcp-cls-inp/</link><pubDate>Fri, 06 Feb 2026 00:00:00 +0000</pubDate><author>Botmonster</author><guid>https://botmonster.com/posts/optimize-core-web-vitals-lcp-cls-inp/</guid><description><![CDATA[<div class="featured-image">
                <img src="/optimize-core-web-vitals-lcp-cls-inp.png" referrerpolicy="no-referrer">
            </div><p>To pass all three Core Web Vitals, target an LCP under 2.5 seconds by preloading your hero image and cutting server response time, a CLS under 0.1 by reserving explicit dimensions for all media, and an INP under 200ms by breaking long JavaScript tasks into smaller chunks. Diagnose all three using Chrome DevTools, Lighthouse, and the CrUX Dashboard for real-user field data.</p>
<h2 id="why-core-web-vitals-matter-for-seo-and-user-experience">Why Core Web Vitals Matter for SEO and User Experience</h2>
<p>Google formally incorporated Core Web Vitals into its ranking algorithm in 2021, but their weight has grown since then. With the March 2026 core update, Google introduced holistic CWV scoring - performance data aggregated across your entire domain rather than judged page by page. If 30% of your indexed pages fail LCP thresholds, that drags down the site-wide score even if your homepage is fast.</p>]]></description></item><item><title>Web Components: Build Framework-Agnostic UI Elements</title><link>https://botmonster.com/posts/web-components-build-framework-agnostic-ui-elements/</link><pubDate>Thu, 05 Feb 2026 00:00:00 +0000</pubDate><author>Botmonster</author><guid>https://botmonster.com/posts/web-components-build-framework-agnostic-ui-elements/</guid><description><![CDATA[<div class="featured-image">
                <img src="/web-components-build-framework-agnostic-ui-elements.png" referrerpolicy="no-referrer">
            </div><p>Web Components are native browser APIs - Custom Elements, Shadow DOM, and HTML Templates - that let you create reusable, encapsulated UI elements like <code>&lt;modal-dialog&gt;</code> or <code>&lt;accordion-panel&gt;</code> that work in React, Vue, Svelte, Angular, or plain HTML without build tools or framework dependencies. With 98% browser support across all modern browsers in 2026, they are the most portable component format available: write it once, ship it anywhere.</p>
<h2 id="the-three-apis-that-make-up-web-components">The Three APIs That Make Up Web Components</h2>
<p>Web Components is an umbrella term for three distinct browser APIs that work together. You can use each independently - Custom Elements without Shadow DOM, Shadow DOM without Templates - but the combination is where they become genuinely useful.</p>]]></description></item></channel></rss>