Skip to content

Commit c2a3fa6

Browse files
committed
feat(logs): Refactor logs for serve
1 parent 5442a84 commit c2a3fa6

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

core/lib/serve.js

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"use strict";
22
const path = require('path');
33
const liveServer = require('live-server');
4+
const logger = require('./log');
45

56
const serve = (patternlab) => {
67

@@ -11,7 +12,8 @@ const serve = (patternlab) => {
1112
ignore: path.join(path.resolve(patternlab.config.paths.public.root)),
1213
file: 'index.html',
1314
logLevel: 0, // errors only
14-
wait: 1000
15+
wait: 1000,
16+
port: 3000
1517
};
1618

1719
// allow for overrides should they exist inside patternlab-config.json
@@ -34,6 +36,8 @@ const serve = (patternlab) => {
3436
//start!
3537
liveServer.start(liveServerConfig);
3638

39+
logger.info(`Pattern Lab is being served from http://127.0.0.1:${liveServerConfig.port}`);
40+
3741
};
3842

3943
module.exports = serve;

0 commit comments

Comments
 (0)