vite-plugin-basic-ssl icon indicating copy to clipboard operation
vite-plugin-basic-ssl copied to clipboard

Invalid certificate

Open cyril-tl opened this issue 3 years ago • 2 comments

I get this error :

Uncaught (in promise) DOMException: Failed to register a ServiceWorker for scope ('https://127.0.0.1:5173/src/') with script ('https://127.0.0.1:5173/src/sw.ts'): An SSL certificate error occurred when fetching the script.

And this is my vite.config.ts file : ` import { fileURLToPath, URL } from "node:url";

import { defineConfig } from "vite"; import vue from "@vitejs/plugin-vue"; import basicSsl from '@vitejs/plugin-basic-ssl'

// https://vitejs.dev/config/ export default defineConfig({ plugins: [ vue(), basicSsl() ], resolve: { alias: { "@": fileURLToPath(new URL("./src", import.meta.url)), }, }, server: { https: true }, }); `

Also, I have vue 3.2.45 and vite 3.2.4. And I launch the dev server with the command npm run dev -- --https

cyril-tl avatar Nov 30 '22 09:11 cyril-tl

Me also having this issue. this issue is going from 2022. i think no body is going to take a look at this.

HNazmul-X avatar Aug 31 '24 02:08 HNazmul-X

If anyone is able to provide a repro or send a PR, we're happy to take a look.

bluwy avatar Feb 25 '25 12:02 bluwy