This is a major issue
So basically the MongoDBToolKit, which is the main class is built to be the main class that can be initialized once and later it's functions like findCollection, deleteCollection can be used. But the problem is that, in many application like express apps have one main file and then many other sub-files like controllers, routes, models, etc. And the @rage-js/tools package will more likely be used on controllers and it's very obvious. But if you have use MongoDBToolKit, you have to get the already initialized one which is in the main file and you can't export that from a main file to a sub-file. This is a bad practice. So better if anyone could find a better solution and fix this ASAP!!!
This is a major issue
So basically the MongoDBToolKit, which is the main class is built to be the main class that can be initialized once and later it's functions like
findCollection,deleteCollectioncan be used. But the problem is that, in many application like express apps have one main file and then many other sub-files likecontrollers,routes,models, etc. And the@rage-js/toolspackage will more likely be used oncontrollersand it's very obvious. But if you have use MongoDBToolKit, you have to get the already initialized one which is in the main file and you can't export that from a main file to a sub-file. This is a bad practice. So better if anyone could find a better solution and fix this ASAP!!!