You've already forked matrix-react-sdk
mirror of
https://github.com/matrix-org/matrix-react-sdk.git
synced 2025-11-05 23:10:41 +03:00
Add experimental "Labs" section to settings
This commit is contained in:
@@ -112,4 +112,14 @@ module.exports = {
|
||||
append: true, // We always append for email pushers since we don't want to stop other accounts notifying to the same email address
|
||||
});
|
||||
},
|
||||
|
||||
isFeatureEnabled: function(feature: string): boolean {
|
||||
feature = feature.match(/\w+/g).join('_').toLowerCase();
|
||||
return localStorage.getItem(`mx_labs_feature_${feature}`) === 'true';
|
||||
},
|
||||
|
||||
setFeatureEnabled: function(feature: string, enabled: boolean) {
|
||||
feature = feature.match(/\w+/g).join('_').toLowerCase();
|
||||
localStorage.setItem(`mx_labs_feature_${feature}`, enabled);
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user