Skip to content

Commit

Permalink
Revert "Add @namespaced directive for namespacing by separation of …
Browse files Browse the repository at this point in the history
…concerns"

This reverts commit b086f46.
  • Loading branch information
spawnia committed Nov 28, 2023
1 parent b086f46 commit 198afbf
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 70 deletions.
45 changes: 0 additions & 45 deletions docs/master/api-reference/directives.md
Original file line number Diff line number Diff line change
Expand Up @@ -2279,51 +2279,6 @@ extend type Query @namespace(field: "App\\Blog") {

A [@namespace](#namespace) directive defined on a field directive wins in case of a conflict.

## @namespaced

```graphql
"""
A no-op nested field resolver that allows nesting of queries and mutations.
"""
directive @namespaced on FIELD_DEFINITION
```

The following example shows how one can namespace queries and mutations.

```graphql
type Query {
posts: PostQueries! @namespaced
}

type PostQueries {
single(
id: ID @eq
): Post! @find

list(
title: String @where(operator: "like")
): [Post!]! @paginate(defaultCount: 10)
}

type Mutation {
posts: PostMutations! @namespaced
}

type PostMutations {
create(
input: PostCreateInput @spread
): Post! @create

update(
input: PostUpdateInput @spread
): Post! @update

delete(
id: ID! @whereKey
): Post @delete
}
```

## @neq

```graphql
Expand Down
25 changes: 0 additions & 25 deletions src/Schema/Directives/NamespacedDirective.php

This file was deleted.

0 comments on commit 198afbf

Please sign in to comment.