I'm using gridform, and also using gridfs-stream itself. I have an existing Grid instance which I would like to be able to pass to gridform, but instead I have to pass the same db and mongo that I used to construct my Grid instance, and then gridform constructs its own Grid instance.
I've poked around a bit in both gridform and gridfs-stream and can't come up with any reason for gridform to need its own Grid instance. I'm happy to send a PR for this, but just want to have some discussion before doing so. I'm imagining just adding a grid field to options which, when provided, is used in place of db and mongo to populate __gridstream. Please let me know your thoughts.
I'm using gridform, and also using gridfs-stream itself. I have an existing
Grid
instance which I would like to be able to pass to gridform, but instead I have to pass the samedb
andmongo
that I used to construct myGrid
instance, and then gridform constructs its ownGrid
instance.I've poked around a bit in both gridform and gridfs-stream and can't come up with any reason for gridform to need its own
Grid
instance. I'm happy to send a PR for this, but just want to have some discussion before doing so. I'm imagining just adding agrid
field tooptions
which, when provided, is used in place ofdb
andmongo
to populate__gridstream
. Please let me know your thoughts.