From 61d935d42afec1f1d44eaba214da52829598fd31 Mon Sep 17 00:00:00 2001 From: yutent Date: Wed, 8 Feb 2023 18:14:06 +0800 Subject: [PATCH] fixed protocol --- lib/constants.js | 2 +- package.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/constants.js b/lib/constants.js index 9ee3153..19742c5 100644 --- a/lib/constants.js +++ b/lib/constants.js @@ -17,7 +17,7 @@ export const COMMON_HEADERS = { export const HMR_SCRIPT = ` !(function(){ - var ws = new WebSocket(\`ws\${location.protocol === 'https' ? 's' : ''}://\${location.host}/ws-vue-live\`) + var ws = new WebSocket(\`ws\${location.protocol === 'https:' ? 's' : ''}://\${location.host}/ws-vue-live\`) ws.addEventListener('open', function (r) { console.log('vue-live hmr ready...') diff --git a/package.json b/package.json index f658a68..479904d 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@bytedo/vue-live", "type": "module", - "version": "0.1.3", + "version": "0.1.4", "bin": { "vue-live": "index.js" },