graphqlite icon indicating copy to clipboard operation
graphqlite copied to clipboard

Preserve type already added

Open fezfez opened this issue 3 years ago • 4 comments

Hello,

With this PR this code will preserve MyCustomInputType

        $factory = new SchemaFactory();
        $factory->setSchemaConfig(SchemaConfig::create([
            'types' => [
                MyCustomInputType::getInstance()
            ]
        ]));

       $schema = $factory->createSchema();

fezfez avatar Jan 12 '23 15:01 fezfez

Is this a good approach ? if it seem to good to you i will fix the tests, otherwise can you provide a good way to do this ?

fezfez avatar Jan 12 '23 15:01 fezfez

@fezfez Can you describe in a bit more detail what it is you're hoping to accomplish here? What's the design challenge you're having in your API? Is it that you're basically wanting a static type? Assuming so, I don't see any point in doing this, as opposed to just programming an input to be static itself.

oojacoboo avatar Jan 13 '23 08:01 oojacoboo

@oojacoboo i have created a very lite sample of my problem at https://github.com/fezfez/sample-graphqlite

fezfez avatar Jan 13 '23 13:01 fezfez

@fezfez , would it be possible to get an explanation of your intended goals here as well? I can see from the code you're trying to create custom types using the webonyx API. But why? Can you explain why you cannot use a normal annotated object, or what the overall goal is?

oojacoboo avatar Jan 18 '23 02:01 oojacoboo

Closing unless this is still needed.

oojacoboo avatar Dec 18 '24 10:12 oojacoboo