Building Composable Layouts in Astro - Simplify Your Website Structure

When working on a website, it’s important to have the ability to divide layouts into separate files. This not only improves organization but also helps avoid the hassle of duplication and makes global changes easier. Traditionally, creating a landing page or another page with a similar structure would involve duplicating code and making individual changes. However, static site builders like Astro offer a solution to this problem. In Astro, layout composition is based on components....

How to Resolve the \"No inputs were found in config file\" Error in tsconfig.json

Many students have encountered the “No inputs were found in config file” error while working on an Astro project, which includes a tsconfig.json file by default. This error typically occurs in VS Code. Although the error may seem puzzling, especially if you are not using TypeScript in your project, there are several possible solutions to fix it. Here are a few steps to troubleshoot this issue: Restart VS Code: Sometimes, a simple restart of the VS Code editor can resolve the error....

Migrating a Basic Site to Astro

In this blog post, I will walk you through the process of moving a website from Hugo to Astro, a simpler solution that eliminates the need to work with Hugo templates when making changes. I find Astro to be a great choice for this migration because it allows me to use JSX, a syntax I am more comfortable with, and also gives me the flexibility to incorporate frameworks like Svelte or React in the future....

New Website and Redesign: Improving Developer Experience and Content Creation

A few days ago, I had a brilliant idea of migrating my website, flaviocopes.com, from Hugo to Astro. In just one day, I successfully accomplished the transition with a fresh new theme design. In this blog post, I will share the entire process and decision-making behind this change, as it may prove useful to you. For those unfamiliar with Astro, it is a fantastic site-building tool that I have been using for many of my latest website projects....

Optimizing Network Data Fetching in Astro

One of the inherent advantages of Astro is its flexible frontmatter feature. Using frontmatter, we can execute JavaScript code, making it exceptionally convenient for fetching data during the build process. Astro leverages the Fetch API which allows us to make network requests with ease. Astro’s frontmatter supports top-level await, eliminating the need for complex solutions such as immediately-invoked function expressions (IIFE) or invoking async functions separately to utilize fetch(), which operates on promises....

The 2023 Bootcamp: Level Up Your Web Development Skills

Welcome to the latest update on the highly anticipated 2023 cohort of bootcamp.dev! Get ready to take your web development skills to the next level with our intensive and comprehensive 10-week online course. The Web Development Bootcamp covers all the essentials, including HTML, CSS, JavaScript, Tailwind, Astro, React, and Next.js. Designed for both beginners and developers with some prior knowledge, this course will equip you with the tools and knowledge needed to succeed in the world of web development....

The stack I use to run this blog

In this post, I will describe the technologies and tools I use to run my blog. From the site platform to hosting, and even my workflow for posting articles, I’ll cover it all. The site platform This blog is built using Astro, a static site framework. While I previously used Hugo, I found that I enjoy creating user interfaces with JSX more. Astro, like Hugo, generates fast pages that can be easily deployed on platforms like Netlify or Cloudflare Pages....