Coder Social home page Coder Social logo

aspnetcore_vite_template's Introduction

AspNetCore_Vite_Template

A Startup Template for ASP.Net Core and Vite project

Feature

  1. Integrating Asp.Net Core and Vite.
  2. Support frontend app HMR
  3. Support HTTPS
  4. Auto build and publish frontend app when publishing backend app
  5. 9 templates -- both Vue and React (JS and TS)
Vue + TypeScript Vue React + TypeScript React
Asp.Net Core MVC 5 O X X X
Net 6 Use Controllers O O O O
Net 6 + Minimal API O O O O

How to use it

VS marketplace : https://marketplace.visualstudio.com/items?itemName=MakotoAtsu.AspNetCoreViteStarter


  1. Install this extension in your VS2019 or VS2022 (download from web page or use VS extension manager)

  1. Create a new project and choose 1 template

image

  1. Press F5 to run both backend and frontend server

image


image


  1. Hit button to fetch data from the backend

image


6. Frontend app will auto-build when you publish the backend app

image


image


If you want to use other Vite template

Just create a new Vite template and replace all content in the ClientApp folder

aspnetcore_vite_template's People

Contributors

makotoatsu avatar pixischris avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

aspnetcore_vite_template's Issues

Adding a Database

Does anyone know how to add a Database in the back-end specifically a MySQL or MySQL Server?

Suggestions

Please consider updating the template to target net6.0. It would also be helpful if you mentioned TypeScript is included as part of the README or in the description of the extension in the Visual Studio marketplace.

npm package in subfolder

Hello. In this template the package.json is in subfolder ClientApp.
If I add a module to package.json this module isn't installed automatically.
Visual Studio requires package.json in root folder.
How you solve this ptoblem?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.