<?xml version="1.0" encoding="utf-8"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Frontend · QuickRef</title><link>https://qref.eknath.dev/tags/frontend/</link><description>Frontend updates from QuickRef</description><language>en-us</language><atom:link href="https://qref.eknath.dev/tags/frontend/index.xml" rel="self" type="application/rss+xml"/><lastBuildDate>Mon, 01 Jan 2024 00:00:00 +0000</lastBuildDate><item><title>Web Development</title><link>https://qref.eknath.dev/links/web-development/</link><guid isPermaLink="true">https://qref.eknath.dev/links/web-development/</guid><pubDate>Mon, 01 Jan 2024 00:00:00 +0000</pubDate><category>web</category><category>frontend</category><category>backend</category><category>javascript</category><category>css</category><description>Essential web development resources and quick references</description><content:encoded><![CDATA[<h2 id="overview">Overview</h2>
<p>Essential web development resources, frameworks, and tools for modern web development.</p>
<h2 id="quick-links">Quick Links</h2>
<h3 id="documentation">Documentation</h3>
<ul>
<li><strong>MDN Web Docs</strong>: <a href="https://developer.mozilla.org">Mozilla Developer Network</a></li>
<li><strong>Can I Use</strong>: <a href="https://caniuse.com">Browser compatibility</a></li>
<li><strong>W3C Standards</strong>: <a href="https://www.w3.org/standards/">Web standards</a></li>
<li><strong>Web.dev</strong>: <a href="https://web.dev">Google web guidance</a></li>
</ul>
<h3 id="frontend-frameworks">Frontend Frameworks</h3>
<ul>
<li><strong>React</strong>: <a href="https://react.dev">Component library</a></li>
<li><strong>Vue.js</strong>: <a href="https://vuejs.org">Progressive framework</a></li>
<li><strong>Angular</strong>: <a href="https://angular.io">Full framework</a></li>
<li><strong>Svelte</strong>: <a href="https://svelte.dev">Compile-time framework</a></li>
</ul>
<h3 id="css-resources">CSS Resources</h3>
<ul>
<li><strong>Tailwind CSS</strong>: <a href="https://tailwindcss.com">Utility-first CSS</a></li>
<li><strong>CSS Grid</strong>: <a href="https://css-tricks.com/snippets/css/complete-guide-grid/">Layout system</a></li>
<li><strong>Flexbox</strong>: <a href="https://css-tricks.com/snippets/css/a-guide-to-flexbox/">Flexible layouts</a></li>
</ul>
<h3 id="code-snippets">Code Snippets</h3>
<div class="highlight"><pre tabindex="0" style="color:#e6edf3;background-color:#0d1117;-moz-tab-size:2;-o-tab-size:2;tab-size:2;"><code class="language-javascript" data-lang="javascript"><span style="display:flex;"><span><span style="color:#8b949e;font-style:italic">// Modern fetch with async/await
</span></span></span><span style="display:flex;"><span><span style="color:#8b949e;font-style:italic"></span><span style="color:#ff7b72">async</span> <span style="color:#ff7b72">function</span> fetchData(url) {
</span></span><span style="display:flex;"><span>    <span style="color:#ff7b72">try</span> {
</span></span><span style="display:flex;"><span>        <span style="color:#ff7b72">const</span> response <span style="color:#ff7b72;font-weight:bold">=</span> <span style="color:#ff7b72">await</span> fetch(url);
</span></span><span style="display:flex;"><span>        <span style="color:#ff7b72">if</span> (<span style="color:#ff7b72;font-weight:bold">!</span>response.ok) {
</span></span><span style="display:flex;"><span>            <span style="color:#ff7b72">throw</span> <span style="color:#ff7b72">new</span> Error(<span style="color:#a5d6ff">`HTTP error! status: </span><span style="color:#a5d6ff">${</span>response.status<span style="color:#a5d6ff">}</span><span style="color:#a5d6ff">`</span>);
</span></span><span style="display:flex;"><span>        }
</span></span><span style="display:flex;"><span>        <span style="color:#ff7b72">const</span> data <span style="color:#ff7b72;font-weight:bold">=</span> <span style="color:#ff7b72">await</span> response.json();
</span></span><span style="display:flex;"><span>        <span style="color:#ff7b72">return</span> data;
</span></span><span style="display:flex;"><span>    } <span style="color:#ff7b72">catch</span> (error) {
</span></span><span style="display:flex;"><span>        console.error(<span style="color:#a5d6ff">&#39;Fetch error:&#39;</span>, error);
</span></span><span style="display:flex;"><span>        <span style="color:#ff7b72">throw</span> error;
</span></span><span style="display:flex;"><span>    }
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div><div class="highlight"><pre tabindex="0" style="color:#e6edf3;background-color:#0d1117;-moz-tab-size:2;-o-tab-size:2;tab-size:2;"><code class="language-css" data-lang="css"><span style="display:flex;"><span><span style="color:#8b949e;font-style:italic">/* Modern CSS Grid Layout */</span>
</span></span><span style="display:flex;"><span>.<span style="color:#f0883e;font-weight:bold">grid-container</span> {
</span></span><span style="display:flex;"><span>    <span style="color:#ff7b72">display</span>: <span style="color:#ff7b72">grid</span>;
</span></span><span style="display:flex;"><span>    <span style="color:#ff7b72">grid-template-columns</span>: <span style="color:#d2a8ff;font-weight:bold">repeat</span>(<span style="color:#79c0ff">auto</span><span style="color:#ff7b72;font-weight:bold">-</span>fit, <span style="color:#d2a8ff;font-weight:bold">minmax</span>(<span style="color:#a5d6ff">300</span><span style="color:#ff7b72">px</span>, <span style="color:#a5d6ff">1</span>fr));
</span></span><span style="display:flex;"><span>    <span style="color:#ff7b72">gap</span>: <span style="color:#a5d6ff">1</span><span style="color:#ff7b72">rem</span>;
</span></span><span style="display:flex;"><span>    <span style="color:#ff7b72">padding</span>: <span style="color:#a5d6ff">1</span><span style="color:#ff7b72">rem</span>;
</span></span><span style="display:flex;"><span>}
</span></span><span style="display:flex;"><span>
</span></span><span style="display:flex;"><span><span style="color:#8b949e;font-style:italic">/* Responsive design with container queries */</span>
</span></span><span style="display:flex;"><span>@<span style="color:#ff7b72">container</span> <span style="color:#ff7b72;font-weight:bold">(</span><span style="color:#7ee787">min-width</span><span style="color:#ff7b72;font-weight:bold">:</span> <span style="color:#7ee787">400px</span><span style="color:#ff7b72;font-weight:bold">)</span> {
</span></span><span style="display:flex;"><span>    .<span style="color:#f0883e;font-weight:bold">card</span> {
</span></span><span style="display:flex;"><span>        <span style="color:#ff7b72">display</span>: <span style="color:#79c0ff">flex</span>;
</span></span><span style="display:flex;"><span>        <span style="color:#ff7b72">flex-direction</span>: <span style="color:#79c0ff">row</span>;
</span></span><span style="display:flex;"><span>    }
</span></span><span style="display:flex;"><span>}
</span></span></code></pre></div><h3 id="tools--resources">Tools &amp; Resources</h3>
<ul>
<li><strong>Vite</strong>: <a href="https://vitejs.dev">Fast build tool</a></li>
<li><strong>Webpack</strong>: <a href="https://webpack.js.org">Module bundler</a></li>
<li><strong>ESLint</strong>: <a href="https://eslint.org">Code linting</a></li>
<li><strong>Prettier</strong>: <a href="https://prettier.io">Code formatting</a></li>
</ul>
<h2 id="key-points">Key Points</h2>
<ul>
<li>Use semantic HTML for accessibility</li>
<li>Implement responsive design with mobile-first approach</li>
<li>Optimize for Core Web Vitals</li>
<li>Use modern JavaScript features (ES6+)</li>
<li>Follow progressive enhancement principles</li>
</ul>
<h2 id="see-also">See Also</h2>
<ul>
<li><a href="https://qref.eknath.dev/programming/">Programming references</a></li>
<li><a href="https://qref.eknath.dev/tools/">Developer tools</a></li>
</ul>
]]></content:encoded></item></channel></rss>