Skip to content
/ shortastic Public template

A URL shortener built with Astro and powered by the Keystatic CMS for content management.

Notifications You must be signed in to change notification settings

xzit/shortastic

Repository files navigation

Shortastic: Astro + Keystatic URL Shortener

πŸ—‚ Project Structure

Inside the project, you'll see the following folders and files:

/
β”œβ”€β”€ public/
β”œβ”€β”€ src/
β”‚   └── content/
β”‚       └── links/
β”‚           └── a1b2c3d4.yaml    # Example: http://localhost:4321/a1b2c3d4
β”‚           └── ...
β”‚   └── pages/
β”‚       └── [...slug].astro
β”‚       └── 404.astro
β”‚       └── index.astro
└── package.json

πŸš€ Getting Started

Caution

Local mode is not safe to use this in production. You should use GitHub mode or Keystatic Cloud instead.

npm install
npm run dev
  1. Open http://localhost:4321/keystatic

  2. Add a new link

    • Generate a slug with nanoid() or use a custom slug
    • Set the redirect URL
    • Set the link as active
  3. Copy the generated short URL

  4. Test it in your browser!

Examples:

About

A URL shortener built with Astro and powered by the Keystatic CMS for content management.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •