https://github.com/rickthehat/datastarexamples
Built using ASP.NET Core Web Apps & Datastar
https://github.com/rickthehat/datastarexamples
asp-net-core asp-net-mvc datastar fastendpoints minimal-api mvc razor-pages
Last synced: 25 days ago
JSON representation
Built using ASP.NET Core Web Apps & Datastar
- Host: GitHub
- URL: https://github.com/rickthehat/datastarexamples
- Owner: RickTheHat
- License: mit
- Created: 2025-01-28T03:54:43.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2025-04-21T20:30:53.000Z (6 months ago)
- Last Synced: 2025-09-08T11:58:53.650Z (about 1 month ago)
- Topics: asp-net-core, asp-net-mvc, datastar, fastendpoints, minimal-api, mvc, razor-pages
- Language: HTML
- Homepage: https://datastar.rickgraner.com
- Size: 2.98 MB
- Stars: 2
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Datastar Examples
### built using [Datastar](https://data-star.dev/) and [ASP.NET Core Web Apps](https://dotnet.microsoft.com/en-us/apps/aspnet)This repository contains implementations of functionality using [Datastar](https://data-star.dev/) & [ASP.NET Core Web Apps](https://dotnet.microsoft.com/en-us/apps/aspnet)
1. *partially working* >>> An [ASP.NET Core Web App](https://learn.microsoft.com/en-us/aspnet/core/data/ef-mvc/intro?view=aspnetcore-9.0) (Model-View-Controller)
2. ****not*** working* >>> An [ASP.NET Core Web App](https://learn.microsoft.com/en-us/aspnet/core/data/ef-rp/intro?view=aspnetcore-9.0&tabs=visual-studio) (Razor Pages)
*for Razor Pages >>> getting a 400 Bad Request error when passing in /Index?handler=Search*
3. *partially working* > An [ASP.NET Core Web App](https://learn.microsoft.com/en-us/aspnet/core/fundamentals/minimal-apis/overview?view=aspnetcore-9.0) (Minimal APIs)
4. ****not*** setup yet* >>> A [FastEndpoints](https://fast-endpoints.com/docs/server-sent-events) project
5. ****not*** setup yet* >>> A [DamianEdwards / RazorSlices](https://github.com/DamianEdwards/RazorSlices) project## Example Page [https://datastar.rickgraner.com](https://datastar.rickgraner.com)
## What is Datastar?
Datastar is a lightweight hypermedia framework that brings reactive functionality to server-rendered applications.
It combines the best of both worlds:
- The simplicity and reliability of server-side rendering
- The dynamic, reactive user experience of a (SPA) Single Page Application w/o the need for JavaScript
- Use JavaScript sparingly and only when you decide## Why Use Datastar?
- **Minimal JavaScript**: Just include a single 14.5 KiB file - smaller than Alpine.js and Htmx combined
- **HATEOAS Compliant**: The only JavaScript you need is the library itself > no additional client-side code required
- **Server Technology Agnostic**: Write your backend in any language
- **Real-time Updates**: Utilizes server-sent events for fast, responsive experiences## Benefits
- **Build Like a Pro, Code Like a Beginner**: Create sophisticated, reactive web applications without wrestling with complex state management or JavaScript frameworks
- **Real-Time Magic**: Update multiple parts of your page instantly - imagine a chat application where messages, user lists, and notifications all update in real-time without writing a single line of JavaScript
- **Your Server, Your Rules**: Keep all your business logic where it belongs - on the server. No more duplicating validation rules or business logic in JavaScript
- **Learn Once, Build Anything**: If you can build a traditional web page, you can build reactive applications. No need to learn Redux, React, or complex state management patterns
- **Instant Feedback**: Create responsive interfaces that feel like native apps - type in a search box and watch results filter instantly, all without complex client-side code
- **Focus on Features, Not Plumbing**: Spend your time building features users love instead of managing state, writing JavaScript, or debugging client-server communication
- **Say Goodbye to Full Page Refreshes**: The dreaded full page refresh is a thing of the past with Datastar - enjoy smooth, partial updates that keep your users in flow## Community
Join our growing community of developers:
- **Discord**: Join our [Discord server](https://discord.gg/bnRNgZjgPh) to:
- Get help with your Datastar projects
- Share your experiences and learn from others
- Stay updated on the latest features and best practices
- Connect with fellow developers- **YouTube**: Subscribe to our [YouTube channel](https://www.youtube.com/@data-star) for:
- Tutorial videos
- Feature demonstrations
- Best practices
- Implementation examples- **GitHub**: Check out the Datastar [library source code](https://github.com/starfederation/datastar/tree/main/library) to:
- Explore the implementation
- Contribute to the project
- Report issues
- Star the repository