1
0
Fork 0
mirror of https://git.sr.ht/~emersion/gamja synced 2025-04-15 08:24:57 -04:00

Add custom title config.json option

References: https://todo.sr.ht/~emersion/gamja/112
This commit is contained in:
Simon Ser 2021-10-20 13:54:58 +02:00
parent a313363ed7
commit ef19ac706c
2 changed files with 7 additions and 1 deletions
README.md
components

View file

@ -106,7 +106,9 @@ gamja default settings can be set using a `config.json` file at the root:
// disable. Enabling PINGs can have an impact on client power usage and
// should only be enabled if necessary.
"ping": 60
}
},
// Custom title (string).
"title": "gamja IRC client"
}
```

View file

@ -192,6 +192,10 @@ export default class App extends Component {
handleConfig(config) {
this.setState({ loading: false });
if (typeof config.title === "string") {
document.title = config.title;
}
let connectParams = { ...this.state.connectParams };
if (config.server) {