gatapia / svelte_dotnet

This project is a bare-bones project template to quickly get started with Svelte on IIS and dotnet

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

.Net Svelte SPA Project Template

This project is a bare-bones project template to quickly get started with the following tech stack:

  • Svelte
  • SvelteKit for routing
  • Carbon Design System
  • C# / .Net 6.0
  • NUnit
  • IIS Hosted (requires IIS URL Rewrite Module)

Getting Started

  • Clone this repository: git clone https://github.com/gatapia/svelte_dotnet_template.git
  • Edit svelte.config.js and replace <project-directory> with the IIS virtual directory/application name
  • Run npm install in the web directory
  • Run release.bat in the root directory, this will create the release directory which can be deployed in IIS
  • Set up a virtual directory/application in IIS pointing to the created release directory
  • Develop by running the srv project on IIS Express (Ctrl + F5 in Visual Studio) and running npm run dev in the dev directory

Important Commands:

  • release.bat updates the release directory for IIS deployment. Note: IIS locks this directory, so for any further releases you will need to stop IIS. This is easily done by killing the w3wp.exe process
  • release_web.bat updates the svelte code in the release\wwwroot directory
  • Run dev server: npm run dev (in web directory)

Important Links:

About

This project is a bare-bones project template to quickly get started with Svelte on IIS and dotnet


Languages

Language:C# 33.8%Language:TypeScript 22.4%Language:Svelte 15.5%Language:JavaScript 10.9%Language:Batchfile 8.8%Language:HTML 7.2%Language:SCSS 1.6%