zaanposni / discord-masz

MASZ is a selfhostable highly sophisticated moderation bot for Discord. Includes a web dashboard and a discord bot.
https://discord.gg/5zjpzw6h3S
Other
71 stars 17 forks source link

Modularize MASZ #466

Closed FeroxFoxxo closed 2 years ago

FeroxFoxxo commented 2 years ago

The idea is relatively simple:

MASZ already has a plugin system, but it is relatively basic. The aim for this feature would be to completely containerize features like automoderation, moderator commands into their own "modules" that can be toggled on/off within the website.

These modules would entirely interface between a revamped plugin system. As such, the plugin system would become on-par with what 3rd party plugin developers would require to develop for MASZ. This abstraction of MASZ could also allow for a addons store in the future.

Due to the interconnectivity of the website, personally this is where I feel the majority of the difficulty would be. We would want to dynamically generate components of the website based on the plugins enabled, plus a way to enable/disable plugins by the site manager.

Ideally, server owners should be able to enable/disable select plugins on a per-guild basis, with the site manager choosing those plugins server owners are able to add.

This would allow for modules like music etc to be easily added and configured by server owners, and would allow the framework to really come into itself imo.

Sidenote: I'm happy to work on the backend side of this as this is my main knowledge source, but it's the frontend that I'm much more unfamiliar with

Not sure if this is the direction you're wanting MASZ to go in, it could be really cool though!

zaanposni commented 2 years ago

For existing "modules" this could be done very easily. We could either add fields to the GuildConfig or create a new table for this and show or hide the tabs/buttons on the website accordingly.

For plugins and additional website components we would have to look into module federation or something similiar as discussed in discord.

It may be better to go for a rewrite of the frontend at that point. Furthermore, this should be combined with further extension fo the plugin system.

FeroxFoxxo commented 2 years ago

MASZ v3 has a pretty good backend plugin system. The frontend is probably the only thing that needs to be reworked but for now it's fine.

FeroxFoxxo commented 2 years ago

This sort of abstracted plugin system isn't really where MASZ is directed to go, so I'm closing this issue!