Skip to content

Commit

Permalink
fixed dev server
Browse files Browse the repository at this point in the history
  • Loading branch information
Hugos68 committed Sep 25, 2023
1 parent ee4cc6a commit b95b79d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/polite-days-suffer.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'capkit': patch
---

Fixed opening dev server and logging out events
6 changes: 5 additions & 1 deletion src/scripts/hotreload.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { exec } from 'child_process';
import { promises as fs } from 'fs';
import { getPM } from '../util/util.js';
import os from 'os';

async function hotreload() {
Expand All @@ -25,7 +26,10 @@ async function hotreload() {
cleanup();

// Run dev server
exec('vite dev');
const pm = getPM();
exec(`${pm === 'npm' ? `${pm} run` : pm} dev --host}`, (error, stdout) => {
console.log(stdout);
});
}

try {
Expand Down

0 comments on commit b95b79d

Please sign in to comment.