Hot Chocolate

GraphQL is a query language and server-side runtime for application programming interfaces (APIs) that prioritizes giving clients exactly the data they request and no more. GraphQL is designed to make APIs fast, flexible, and developer-friendly.

https://www.opencodez.com/web-development/tutorial6-51-imp-graphql-interview-questions-answers.htm 

Hot Chocolate is an open-source GraphQL server built for the Microsoft .NET platform. It removes the complexity of building GraphQL APIs from scratch with built-in features for queries, mutations, and subscriptions

We’ll be building a GraphQL API backend with Hot Chocolate GraphQL 

Resolvers are functions that tell the Hot Chocolate GraphQL server how to fetch the data associated with a particular schema. In simple terms, a resolver acts as a GraphQL query handle

  • Open your browser and head over to the port your GraphQL server is listening on (ours is http://localhost:5000/graphql) to open the Hot Chocolate built-in GraphQL IDE Banana Cake Pop
  • we will use our GraphQL IDE Banana Cake Pop.
If you have setup everything correctly, you should be able to open http://localhost:5000/graphql (the port might be different for you) in your browser and be greeted by our GraphQL IDE Banana Cake Pop.

you'll learn by building a full-featured GraphQL Server with ASP.NET Core and Hot Chocolate from scratch. We'll start from File/New and build up a full-featured GraphQL server with custom middleware, filters, subscription and relay support.


 SELECT *
    FROM "Engines"  e, "Rockets"  r
    WHERE r."Id" = e."RocketId"

select        eng."Name" AS Engine_name,
              roc."Name" AS roc_name             
FROM          "Engines" eng
              INNER JOIN "Rockets" roc ON roc."Id" = eng."RocketId" 

  • run npm install  to ensure all deps are downloaded

  • Scaffold-DbContext "Host=localhost;Database=magic5;Username=postgres;Password=sa" Npgsql.EntityFrameworkCore.PostgreSQL -OutputDir Models


Apollo Client is a fully-featured caching GraphQL client with integrations for React, Angular, and more. It allows you to easily build UI components that fetch data via GraphQL.


Apollo Client :

A powerful JavaScript GraphQL client, designed to work well with React, React Native, Angular 2, or just plain JavaScript.


Apollo Client is a comprehensive state management library for JavaScript that enables you to manage both local and remote data with GraphQL. Use it to fetch, cache, and modify application data, all while automatically updating your UI.


Apollo Client is a state management library that simplifies managing remote and local data with GraphQL. Apollo Client's intelligent caching and declarative approach to data fetching can help you iterate faster while writing less code. Additionally, if you need custom functionality, you can create your dream client by building extensions on top of Apollo Client


---------------------------------------

<p id="demo"></p>  

<script>

hello = function() {

  return "Hello World!";

}

document.getElementById("demo").innerHTML = hello();

-------------------------------------------------------------

<body> 

<p id="demo"></p>

  

<script>

hello = () => {

  return "Hello World!";

}


document.getElementById("demo").innerHTML = hello();

</script>


</body>

</html>

--------------------------------

<body>  

<script>

class Car {

  constructor(name) {

    this.brand = name;

  }

  present() {

    return 'I have a ' + this.brand;

  }

}

const mycar = new Car("Ford");

mycar.present();

</script>

</body>











Comments

Popular posts from this blog

Travel RESUME CV

PTE