mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-13 09:33:54 +00:00
chalk OPEN color
This commit is contained in:
parent
c26daa9e8f
commit
289c6f2214
@ -1,7 +1,7 @@
|
|||||||
import http from 'http'
|
import http from "http";
|
||||||
import connect from 'connect'
|
import connect from "connect";
|
||||||
import path from 'path'
|
import path from "path";
|
||||||
import chalk from 'chalk'
|
import chalk from "chalk";
|
||||||
|
|
||||||
class Server {
|
class Server {
|
||||||
constructor (nuxt) {
|
constructor (nuxt) {
|
||||||
@ -70,7 +70,7 @@ class Server {
|
|||||||
this.server.listen(port, host, () => {
|
this.server.listen(port, host, () => {
|
||||||
let _host = host === '0.0.0.0' ? 'localhost' : host
|
let _host = host === '0.0.0.0' ? 'localhost' : host
|
||||||
// eslint-disable-next-line no-console
|
// eslint-disable-next-line no-console
|
||||||
console.log('\n' + chalk.bold(chalk.bgBlue.white(' OPEN ') + chalk.blue(` http://${_host}:${port}\n`)))
|
console.log('\n' + chalk.bold(chalk.bgBlue.black(' OPEN ') + chalk.blue(` http://${_host}:${port}\n`)))
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
.catch(this.nuxt.errorHandler)
|
.catch(this.nuxt.errorHandler)
|
||||||
|
Loading…
Reference in New Issue
Block a user