Offix-datasync requires a lot of boilerplate code that we can generate. A lot of the features we need to extract from graphql schema have been done here in graphback-cli, so to reuse this code and ease maintenance, we will create plugin here to generate code for offix-datasync.
@wtrocki @kingsleyzissou @ssd71
Awesome! We can have this plugin in offix repository. Challenge would be to figure out how to load this plugin as we will need to do it in the code - which prevents us from using graphback-cli.
Some technical debt in graphback-cli needs to be addressed to be able to load external plugins (we removed that capability as it was in graphback.
CC @craicoverflow @machi1990
Challenge would be to figure out how to load this plugin as we will need to do it in the code - which prevents us from using graphback-cli.
Question. Why will it need to be in code? Is this because the dynamic plugin loader only worked for graphback namespaced packages like @graphback/plugin-x?
Some technical debt in graphback-cli needs to be addressed to be able to load external plugins (we removed that capability as it was in graphback.
External plugins can be loaded through the .graphqlrc, this functionality was not removed if I am not mistaken? The limitation being that packages that are namespaced cannot be loaded through the .graphqlrc (this is YAML limitation as keys cannot start with "@".
Question. Why will it need to be in code? Is this because the dynamic plugin loader only worked for graphback namespaced packages like @graphback/plugin-x?
We no longer have this feature (I wasn't the one who have removed it :P)
External plugins can be loaded through the .graphqlrc, this functionality was not removed if I am not mistaken?
I do not see this anywhere. We talked on PR about moving this logic from Graphback to the cli... but this never happened. We have lost the same features on graphql-serve CLI as well.
I would look for your recomendation what we should do here.
We definitely:
@wtrocki I ran an experiment to check this. I created a simple plugin to indicate when its been called. I linked this plugin to a sample graphback app and added it to .graphqlrc. It worked. The plugin was actually loaded and it's createResources function was executed
So external plugins can be loaded. The only constraint is that, the plugin name cannot start with "graphback"
Just to make sure. What is your graphback version? I tried it and plugin was not lodaded with 0.14.0 but it might be something wrong on my side
I used 0.14.0 @wtrocki
ok. then we have no problem to do new plugin
Most helpful comment
ok. then we have no problem to do new plugin