Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/background.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ function startServer() {

debugBarServer = net.createServer();

debugBarServer.listen(mainStorage.get('port'), '0.0.0.0', () => {
console.log('TCP Server is running on port ' + mainStorage.get('port'));
debugBarServer.listen(mainStorage.get('port'), mainStorage.get('host'), () => {
console.log('TCP Server is running on port ' + mainStorage.get('port') + ' and host ' + mainStorage.get('host'));
});


Expand Down
19 changes: 18 additions & 1 deletion src/components/settings.vue
Original file line number Diff line number Diff line change
Expand Up @@ -90,6 +90,20 @@
</div>
</div>

<div class="col-span-6">
<label
for="host"
class="block text-sm font-medium leading-5 text-gray-700"
>Host</label>
<div class="mt-1 rounded-md shadow-sm">
<input
type="text"
v-model="host"
id="host"
class="form-input rounded block w-full transition duration-150 ease-in-out sm:text-sm sm:leading-5"
/>
</div>
</div>
<div class="col-span-6">
<label
for="port"
Expand Down Expand Up @@ -136,6 +150,7 @@ export default {
editor: 'vscode',
followRequests: true,
port: 2304,
host: "127.0.0.1",
};
},

Expand All @@ -151,11 +166,13 @@ export default {
this.port = mainStorage.get("port");
this.editor = mainStorage.get("editor");
this.followRequests = mainStorage.get("followRequests");
this.host = mainStorage.get("host");
},

save() {
mainStorage.set({
port: this.port,
host: this.host,
followRequests: this.followRequests,
editor: this.editor,
});
Expand All @@ -170,4 +187,4 @@ export default {
this.fetch();
}
};
</script>
</script>
3 changes: 2 additions & 1 deletion src/static/settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
{
"port": 2304,
"host": "127.0.0.1",
"editor": "vscode",
"followRequests": true
}
}