Skip to content

Commit 729d197

Browse files
authored
fix(minor): default server to http://localhost to open it with Ctrl+Click (#94)
1 parent 97ece42 commit 729d197

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ Use this script to inject the target code into your webpage.
5656
<script src="//host-machine-ip:8080/target.js"></script>
5757
```
5858

59-
Then browse to localhost:8080 to start debugging your page.
59+
Then browse to http://localhost:8080 to start debugging your page.
6060

6161
For more detailed usage instructions, please read the documentation at [chii.liriliri.io](https://chii.liriliri.io/docs/)!
6262

bin/chii.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ program
1111
.description('starts chii server')
1212
.option('-p, --port <port>', 'set the port to start on. defaults to 8080', parseInt)
1313
.option('-h, --host <host>', 'set the host. defaults to 0.0.0.0')
14-
.option('-d, --domain <domain>', 'set the domain. defaults to localhost:port')
14+
.option('-d, --domain <domain>', 'set the domain. defaults to http://localhost:port')
1515
.option('--base-path <basePath>', 'set base path. defaults to /')
1616
.option('--cdn <cdn>', 'use cdn like jsdelivr')
1717
.option('--https', 'serve chii over https')

server/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ async function start({
1919
sslKey,
2020
basePath = '/',
2121
} = {}) {
22-
domain = domain || 'localhost:' + port;
22+
domain = domain || 'http://localhost:' + port;
2323
if (!endWith(basePath, '/')) {
2424
basePath += '/';
2525
}

0 commit comments

Comments
 (0)