Open spencermize opened 1 year ago
I can see that this issue has been marked as OGM 2.0 Could I create a PR to simply pass in a configuration object that'll overwrite the existing one? I think it could improve DX a lot because you don't need to create two different but similar generated files.
Is your feature request related to a problem? Please describe. I'd like to have a bit more control over the types that are generated - specifically, I'd like to utilize some other
graphql-codegen
plugins to create Types based upon my queries, which means I'd like access to multiple config options in the existing configuration object.Describe the solution you'd like Allowing the passing of an options object that gets assigned here https://github.com/neo4j/graphql/blob/0586a960a51236547a55d419e0ce29acdc47fb3b/packages/ogm/src/generate.ts#L138 would be awesome!
Describe alternatives you've considered I have generated my own types using similar code as what's in
generate()
, but this causes me to have to run the typegen twice - once for OGM, and once for my queries. This also results in two files with significant overlaps.Thanks for considering this!!