live-server icon indicating copy to clipboard operation
live-server copied to clipboard

How could I start and stop live-server in js(html) language instead terminal?

Open Yes-Jumby opened this issue 4 years ago • 1 comments

hi,everyone: Now I could use code to start live-server,but I cannot stop it ,could someone give me a hand?

Yes-Jumby avatar Jul 02 '20 02:07 Yes-Jumby

The docs don't mention this. I found the solutions here: https://github.com/tapio/live-server/issues/169#issuecomment-270846429

// Start
liveServer.start({ /* Options */ });

// Stop
liveServer.shutdown();

jhildenbiddle avatar Jul 06 '20 09:07 jhildenbiddle