Astro

Astro is a frontend framework for static website generation that allows for embedded #javascript or #typescript inside HTML files. This means that we can incorporate other JavaScript frontend framework such as React.js, Vue.js, Svelte etc. into an Astro project.

The special tag <slot /> could be used as a placeholder in component file to hold HTML content in an Astro file after importing to the main HTML component.

To define JavaScript variables or import files, we should contain them into a three dashes fence at the start of the Astro file. The syntax is shown as follows:

---
const variable = "Some value";
---

<h1>This is {variable}</h1>
#web #frontend #javascript #typescript