scttcper/qbittorrent

split up methods from index.ts

sachaw opened this issue · 1 comments

As the number of methods supported by this repo grows (nearly 800 lines) it becomes increasingly unmaintainable, I suggest that index.ts gets turned into a module loader and exporter of sorts and split all methods into there respective files under /src/methods @scttcper what are your thoughts on this, mainly how you think such a module loader should be implmented?

I'm not too worried about the size so far, I really only care about the normalized functions that are common to the other torrent clients. Could move things out of the class like _normalizeTorrentData and after looking at some things, things like returning "true" instead of void is probably not doing much.

Maybe the normalized functionality is pulled out in some way? But then would need to be done in every client.