Read auto-join channels from browser URL hash
This is easier to type than trying to escape the # in ?channels=#XXX.
This commit is contained in:
@@ -252,6 +252,10 @@ export default class App extends Component {
|
||||
connectParams.autojoin = queryParams.channels.split(",");
|
||||
}
|
||||
|
||||
if (window.location.hash) {
|
||||
connectParams.autojoin = window.location.hash.split(",");
|
||||
}
|
||||
|
||||
this.setState((state) => {
|
||||
return { connectParams: { ...state.connectParams, ...connectParams } };
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user