Skip to content

Commit

Permalink
fix: update apply patches documentation (#815)
Browse files Browse the repository at this point in the history
  • Loading branch information
backlineint authored Nov 7, 2024
1 parent 1251912 commit cd487e2
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 30 deletions.
22 changes: 6 additions & 16 deletions www/content/tutorials/graphql/apply-patches.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,45 +5,35 @@ weight: 30
group: Quick Start (GraphQL)
---

At the time of this writing, a patch is required in order to use multilingual features such as translation.

<Callout>

In a future release, these patches will NOT be required for using Next.js and GraphQL.
**Note:** If you're not using multilingual features such as translation, you can skip this step.

</Callout>

At the time of this writing, there are two patches we need to wire everything together.

1. Open your Drupal `composer.json` file.
2. Add the following patches under `"extra"`.
2. Add the following patch under `"extra"`.

```json title=composer.json
"extra": {
// highlight-start
"patches": {
"drupal/subrequests": {
"Get same results on different request": "https://www.drupal.org/files/issues/2019-07-18/change_request_type-63049395-09.patch"
},
"drupal/decoupled_router": {
"Unable to resolve path on node in other language than default": "https://www.drupal.org/files/issues/2022-11-30/decouple_router-3111456-resolve-language-issue-58.patch"
"Unable to resolve path on node in other language than default": "https://www.drupal.org/files/issues/2024-10-22/decoupled_router-3111456-resolve-langcode-issue-78--external-redirects.patch"
}
},
// highlight-end
}
```

<Callout>

**Note:** If you're not using multilingual features such as translation, you can skip the second patch.

</Callout>

3. Run the following command:

```sh
composer require cweagans/composer-patches
```

You can read more about the patches here:
You can read more about the patch here:

1. https://www.drupal.org/project/subrequests/issues/3049395
2. https://www.drupal.org/project/decoupled_router/issues/3111456
24 changes: 10 additions & 14 deletions www/content/tutorials/quick-start/apply-patches.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,39 +5,35 @@ weight: 30
group: Quick Start
---

At the time of this writing, there are two patches we need to wire everything together.
At the time of this writing, a patch is required in order to use multilingual features such as translation.

<Callout>

**Note:** If you're not using multilingual features such as translation, you can skip this step.

</Callout>

1. Open your Drupal `composer.json` file.
2. Add the following patches under `"extra"`.
2. Add the following patch under `"extra"`.

```json title=composer.json
"extra": {
// highlight-start
"patches": {
"drupal/subrequests": {
"Get same results on different request": "https://www.drupal.org/files/issues/2019-07-18/change_request_type-63049395-09.patch"
},
"drupal/decoupled_router": {
"Unable to resolve path on node in other language than default": "https://www.drupal.org/files/issues/2022-11-30/decouple_router-3111456-resolve-language-issue-58.patch"
"Unable to resolve path on node in other language than default": "https://www.drupal.org/files/issues/2024-10-22/decoupled_router-3111456-resolve-langcode-issue-78--external-redirects.patch"
}
},
// highlight-end
}
```

<Callout>

**Note:** If you're not using multilingual features such as translation, you can skip the second patch.

</Callout>

3. Run the following command:

```sh
composer require cweagans/composer-patches
```

You can read more about the patches here:
You can read more about the patch here:

1. https://www.drupal.org/project/subrequests/issues/3049395
2. https://www.drupal.org/project/decoupled_router/issues/3111456

0 comments on commit cd487e2

Please sign in to comment.