From 7c70dcb0dc2c77b60bec16293c7c7d4677097520 Mon Sep 17 00:00:00 2001 From: Ariel Mashraki <7413593+a8m@users.noreply.github.com> Date: Wed, 3 Feb 2021 11:29:56 +0200 Subject: [PATCH] doc/graphql: fix broken links to ent-contrib --- doc/md/graphql.md | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/doc/md/graphql.md b/doc/md/graphql.md index f1937e250..cceb22f42 100644 --- a/doc/md/graphql.md +++ b/doc/md/graphql.md @@ -8,7 +8,7 @@ library using the [external templates](templates.md) option (i.e. it can be exte ## Quick Introduction -In order to enable the [`entgql`](https://entgo.ioincubator/ent-contrib/tree/master/entgql) extension to your +In order to enable the [`entgql`](https://github.com/facebookincubator/ent-contrib/tree/master/entgql) extension to your project, you need to use the `entc` (ent codegen) package as described [here](code-gen.md#use-entc-as-a-package). Follow these 3 steps to enable it to your project: @@ -24,7 +24,7 @@ import ( "entgo.io/ent/entc" "entgo.io/ent/entc/gen" - "entgo.ioincubator/ent-contrib/entgql" + "entgo.io/contrib/entgql" ) func main() { @@ -46,7 +46,7 @@ package ent ``` Note that `ent/entc.go` is ignored using a build tag, and it's executed by the `go generate` command -through the `generate.go` file. The full example can be found in the [ent-contrib repository](https://entgo.ioincubator/ent-contrib/blob/master/entgql/internal/todo). +through the `generate.go` file. The full example can be found in the [ent-contrib repository](https://github.com/facebookincubator/ent-contrib/blob/master/entgql/internal/todo). 3\. Run codegen for your ent project: @@ -86,7 +86,7 @@ func (r *queryResolver) Node(ctx context.Context, guid string) (ent.Noder, error ## GQL Configuration -Here's a configuration example for a todo app as exists in [ent-contrib/entgql/todo](https://entgo.ioincubator/ent-contrib/tree/master/entgql/internal/todo). +Here's a configuration example for a todo app as exists in [ent-contrib/entgql/todo](https://github.com/facebookincubator/ent-contrib/tree/master/entgql/internal/todo). ```yaml schema: @@ -100,7 +100,7 @@ resolver: # gqlgen will search for any type names in the schema in the generated # ent package. If they match it will use them, otherwise it will new ones. autobind: - - entgo.ioincubator/ent-contrib/entgql/internal/todo/ent + - entgo.io/contrib/entgql/internal/todo/ent models: ID: @@ -109,7 +109,7 @@ models: Node: model: # ent.Noder is the new interface generated by the Node template. - - entgo.ioincubator/ent-contrib/entgql/internal/todo/ent.Noder + - entgo.io/contrib/entgql/internal/todo/ent.Noder ``` ## Pagination @@ -131,7 +131,7 @@ The ordering option allows us to apply an ordering on the edges returned from a ### Example Let's go over the steps needed in order to add ordering to an existing GraphQL type. -The code example is based on a todo-app that can be found in [ent-contrib/entql/todo](https://entgo.ioincubator/ent-contrib/tree/master/entgql/internal/todo). +The code example is based on a todo-app that can be found in [ent-contrib/entql/todo](https://github.com/facebookincubator/ent-contrib/tree/master/entgql/internal/todo). ### Defining order fields in ent/schema @@ -353,12 +353,12 @@ func (mutationResolver) CreateTodo(ctx context.Context, todo TodoInput) (*ent.To ## Examples -The [ent-contrib](https://entgo.ioincubator/ent-contrib) contains several examples at the moment: -1. A complete GraphQL server with a simple [Todo App](https://entgo.ioincubator/ent-contrib/tree/master/entgql/internal/todo) with numeric ID field -2. The same [Todo App](https://entgo.ioincubator/ent-contrib/tree/master/entgql/internal/todouuid) in 1, but with UUID type for the ID field -3. The same [Todo App](https://entgo.ioincubator/ent-contrib/tree/master/entgql/internal/todopulid) in 1 and 2, but with a prefixed [ULID](https://github.com/ulid/spec) or `PULID` as the ID field. This example supports the Relay Node API by prefixing IDs with the entity type rather than employing the ID space partitioning in [Universal IDs](migrate.md#universal-ids). +The [ent-contrib](https://github.com/facebookincubator/ent-contrib) contains several examples at the moment: +1. A complete GraphQL server with a simple [Todo App](https://github.com/facebookincubator/ent-contrib/tree/master/entgql/internal/todo) with numeric ID field +2. The same [Todo App](https://github.com/facebookincubator/ent-contrib/tree/master/entgql/internal/todouuid) in 1, but with UUID type for the ID field +3. The same [Todo App](https://github.com/facebookincubator/ent-contrib/tree/master/entgql/internal/todopulid) in 1 and 2, but with a prefixed [ULID](https://github.com/ulid/spec) or `PULID` as the ID field. This example supports the Relay Node API by prefixing IDs with the entity type rather than employing the ID space partitioning in [Universal IDs](migrate.md#universal-ids). --- -Please note that this documentation is under development. All code parts reside in [ent-contrib/entgql](https://entgo.ioincubator/ent-contrib/tree/master/entgql), -and an example of a todo-app can be found in [ent-contrib/entql/todo](https://entgo.ioincubator/ent-contrib/tree/master/entgql/internal/todo). +Please note that this documentation is under development. All code parts reside in [ent-contrib/entgql](https://github.com/facebookincubator/ent-contrib/tree/master/entgql), +and an example of a todo-app can be found in [ent-contrib/entql/todo](https://github.com/facebookincubator/ent-contrib/tree/master/entgql/internal/todo).