david-tejada / rango

🦎 The cross browser extension that helps you control your browser by voice. It blends in!
MIT License
129 stars 17 forks source link

add support for importing and exporting rule sets #308

Open heartpunk opened 1 month ago

heartpunk commented 1 month ago

As I mentioned in #307 I just got done adding custom rules for blue sky (a twitter clone), and was just wondering if there was any way to; export or import rules. I didn't see any such mechanism so I wanted to suggest the possibility of adding one.

I also might be willing to help pitch in on this one as I think it could be something I could manage and also a fun little project that would help some other people out. I wouldn't want to get started on it though before discussing the design approach, as I think that's quite important in making sure that the PR lands.

david-tejada commented 3 weeks ago

This is a good idea. I had already thought of something like this but for all the settings not just custom hints. I think it makes more sense to have the ability to export and import all the settings.

You can have a go at it. It probably makes sense to have two buttons down at the bottom of the settings page. One for importing and one for exporting. The exporting button would generate json with the settings grabbed from the extension local/sync storage. This json could then be used when importing. You then would go over every setting in the json and store the new value. If you feel adventurous you could have an intermediate dialog when exporting to select which settings to export.