feat(server): display a url when server starts to make it clickable
This commit is contained in:
6
bin/www
6
bin/www
@@ -75,8 +75,6 @@ function onError (error) {
|
|||||||
*/
|
*/
|
||||||
function onListening () {
|
function onListening () {
|
||||||
const addr = server.address()
|
const addr = server.address()
|
||||||
const bind = typeof addr === 'string'
|
const uri = typeof addr === 'string' ? addr : `http://localhost:${addr.port}`
|
||||||
? 'pipe ' + addr
|
console.log(`Listening on ${uri}`)
|
||||||
: 'port ' + addr.port
|
|
||||||
console.log('Listening on ' + bind)
|
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user