Skip to content

granicz/fullstack-spa

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A full-stack F# SPA template with charts and forms

Requirements

  • .NET SDK 6.0 or above
  • npm

Features

Server

  • WebSharper sitelets for RPC

Client

Running it

You can run the full app in watch mode using

dotnet run

This starts vite on port 5173 and the server on port 5001, listens to file changes in the entire solution and recompiles changes on the fly (TEMP: this is not entirely true as of yet: if you make changes in the shared project, you need to stop and re-run dotnet run from the root).

To view the app, navigate to

https://localhost:5173

Alternatively, you can start the server and client separately:

// Terminal #1
> cd src/server
> dotnet run

// Terminal #2
> cd src/client
> dotnet ws build     // or "dotnet build"
> dotnet serve

Release mode (not yet fully working)

To build the solution in release mode, you can use:

> cd src/client
> npx vite build

This will build the client bundle into the top-level dist folder. You will need to manually copy over the assets folder from src/client/assets.

TODO: Document how to configure the server.

About

A full-stack F# SPA with WebSharper

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published