From cdc3c4b3d2b2ed3b245e34108546adb03f158f9e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?t=C9=99=C9=99na=2Evu=C9=99?= <76698025+franklin-tina@users.noreply.github.com> Date: Wed, 6 Mar 2024 07:25:23 -0600 Subject: [PATCH] docs: add documentation for using layers with private repos (#26094) --- docs/1.getting-started/9.layers.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/docs/1.getting-started/9.layers.md b/docs/1.getting-started/9.layers.md index ed61136af1af..eb35638d0383 100644 --- a/docs/1.getting-started/9.layers.md +++ b/docs/1.getting-started/9.layers.md @@ -29,6 +29,19 @@ export default defineNuxtConfig({ }) ``` +You can also pass an authentication token if you are extending from a private GitHub repository: + +```ts twoslash [nuxt.config.ts] +export default defineNuxtConfig({ + extends: [ + // per layer configuration + ['github:my-themes/private-awesome', { auth: process.env.GITHUB_TOKEN }] + ] +}) +``` + +Nuxt uses [unjs/c12](https://c12.unjs.io) and [unjs/giget](https://giget.unjs.io) for extending remote layers. Check the documentation for more information and all available options. + ::read-more{to="/docs/guide/going-further/layers"} Read more about layers in the **Layer Author Guide**. ::