Skip to content

3nvi/personal-website-astro

Repository files navigation

Personal Website

This is the source code for my personal website, built using Astro.

Development Setup

  1. Clone the repository:

    git clone <your-repository-url>
    cd <repository-directory>
  2. Install dependencies:

    npm install

    Note: This project uses Node.js. Make sure you have a compatible version installed.

  3. Environment Variables: Copy the example environment file .env.local.example to .env.local:

    cp .env.local.example .env.local

    Then, fill in the required values in .env.local. These variables are necessary for features like the contact form and analytics during local development.

  4. Run the development server:

    npm run dev

    This command starts the local development server. Open your browser and navigate to http://localhost:4321 (or the address shown in the terminal) to see the website.

Available Scripts

The following scripts are available via npm run <script_name>:

Command Action
dev Starts the local development server
build Builds the production-ready site to the ./dist/ directory
preview Serves the production build locally for preview
astro ... Executes Astro CLI commands (e.g., astro check)

Running Production Build Locally

To test the production build on your local machine:

  1. Build the site:

    npm run build

    This command creates an optimized version of your site in the ./dist/ directory.

  2. Preview the build:

    npm run preview

    This command starts a local server to serve the files from ./dist/, allowing you to preview the production site before deployment. Open your browser to the address provided in the terminal.

About

A reimplementation of my personal website (originally in GatsbyJS) written in Astro

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •