sindresorhus / open

Open stuff like URLs, files, executables. Cross-platform.
MIT License
3.18k stars 219 forks source link

check if browser process is running event ? #282

Closed robeverett closed 2 years ago

robeverett commented 2 years ago

This works great for my node express app:

app.listen(3000, () => { console.log('Serving on port 3000...'); open('http://localhost:3000'); });

Just one problem, if I restart the node server, it opens a new instance / tab in Chrome. I would like to be able just to cause a browser refresh instead within the above code. Anyway to achieve this ?

sindresorhus commented 2 years ago

Duplicate of #256