Elegua

screenshot of Elegua
svelte
vite

Elegua - a small, reactive PWA router for Svelte

Overview

Elegua is a lightweight and intuitive micro client router designed for Svelte applications, making it an excellent choice for developers seeking simplicity and flexibility. With its minimalistic approach, Elegua eliminates the need for traditional components, allowing users to manage routing using Svelte's logical blocks. This enables a more natural and seamless integration into Svelte projects, making it a standout option among existing routers.

This router emphasizes a dependency-free setup, leveraging only the Svelte framework. Its small footprint, combined with a fully reactive design, ensures that changes in the application state are reflected in the browser's URL, and vice versa. If you're looking for a straightforward solution to implement routing without the bloat, Elegua might just be what you need.

Features

  • Dependency Free: Elegua requires no additional dependencies other than Svelte, making it easy to integrate and lightweight.
  • Intuitive API: The design feels natural for developers, utilizing plain Svelte logical blocks for routing instead of complex components.
  • Minimalist Design: Everything you need comes in a single file, compact at 2.2KB gzipped, allowing for faster load times.
  • Tree-shakable: The router can become even smaller based on the features you utilize, optimizing your bundle size.
  • Fully Reactive: Changes to the application state are immediately reflected in the browser's URL, ensuring a seamless user experience.
  • Dynamic and Fixed Routing: Support for fixed path routes, variable routes, and regular expression routes provides versatility for complex routing needs.
  • Prevent Route Changes: Unique functions like preventUnload() and preventChange() allow you to manage route transitions under specific conditions.
  • Fast Performance: Elegua's approach to routing is designed for speed, avoiding the overhead of additional components and complex logic.
svelte
Svelte

Svelte is a modern front-end framework that compiles your code at build time, resulting in smaller and faster applications. It uses a reactive approach to update the DOM, allowing for high performance and a smoother user experience.

vite
Vite

Vite is a build tool that aims to provide a faster and leaner development experience for modern web projects

eslint
Eslint

ESLint is a linter for JavaScript that analyzes code to detect and report on potential problems and errors, as well as enforce consistent code style and best practices, helping developers to write cleaner, more maintainable code.

Pwa

A Progressive Web App (PWA) is a type of web application that uses modern web technologies to provide a native app-like experience to users, including offline functionality, push notifications, and device hardware access. PWAs can be installed on a user's home screen and launched like a traditional app, but do not require a separate app store listing or download.

typescript
Typescript

TypeScript is a superset of JavaScript, providing optional static typing, classes, interfaces, and other features that help developers write more maintainable and scalable code. TypeScript's static typing system can catch errors at compile-time, making it easier to build and maintain large applications.