Skip to content

joeldenning/vite-single-spa-example

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

vite-single-spa-example

This shows a vite application that functions as a single-spa application.

Local dev

Single-spa playground

pnpm install
pnpm run dev -- --https
open https://localhost:3000/src/main.js # The cert will be insecure - tell your browser to trust it
open 'https://single-spa-playground.org/playground/instant-test?name=vite-test&framework=vue&useNativeModules=true&url=https%3A%2F%2Flocalhost%3A3000%2Fsrc%2Fmain.js'

The url to go to when developing is https://single-spa-playground.org/playground/instant-test?name=vite-test&framework=vue&useNativeModules=true&url=https%3A%2F%2Flocalhost%3A3000%2Fsrc%2Fmain.js

The URL to be used when setting up import map overrides is https://localhost:3000/src/main.js

Root config

See https://github.com/joeldenning/vite-single-spa-root-config which shows a root config that loads up this vite application

To-do

  1. Merge single-spa/single-spa-playground#37
  2. Get vuejs/core#2477 merged and published
  3. Get build working by modifying rollup output options to compile to systemjs format
  4. Add documentation to single-spa.js.org (single-spa/single-spa.js.org#352)