I am developing a Blazor application initially as a Blazor Server app but the longer term goal is to deploy the same application in a web assembly + server configuration.
My preference would be to adopt GraphQL from the 1st day of coding while the Blazor Server prototype is created but this creates a situation where GraphQL client code and HotChocolate server code run in the same process. Is this possible?
The following code in the HotChocolate docs shows it is possible to submit GraphQL queries to Hotchocolate by expressing a query in schema.Execute(q) however I would prefer to code the full GraphQL stack and just skip the network activity when the full stack is running in a single Blazor server process.
https://github.com/ChilliCream/hotchocolate-docs/blob/master/docs/introduction.md
public class Query
{
public string Hello() => "World!";
}
var schema = SchemaBuilder.New().AddQueryType<Query>().Create();
var executor = schema.MakeExecutable();
Console.WriteLine(executor.Execute("{ hello }").ToJson());