2021-11-19 12:22:27 +00:00
|
|
|
export default {
|
|
|
|
/**
|
|
|
|
* Configure Nuxt component auto-registration.
|
|
|
|
*
|
|
|
|
* Any components in the directories configured here can be used throughout your
|
|
|
|
* pages, layouts (and other components) without needing to explicitly import them.
|
|
|
|
*
|
|
|
|
* @default {{ dirs: [`~/components`] }}
|
2022-04-12 09:59:32 +00:00
|
|
|
* @see [Nuxt 3](https://v3.nuxtjs.org/guide/directory-structure/components) and
|
2021-11-19 12:22:27 +00:00
|
|
|
* [Nuxt 2](https://nuxtjs.org/docs/directory-structure/components/) documentation
|
|
|
|
* @type {boolean | typeof import('../src/types/components').ComponentsOptions | typeof import('../src/types/components').ComponentsOptions['dirs']}
|
2022-03-22 17:04:31 +00:00
|
|
|
* @version 2
|
|
|
|
* @version 3
|
2021-11-19 12:22:27 +00:00
|
|
|
*/
|
|
|
|
components: {
|
|
|
|
$resolve: (val, get) => {
|
2022-02-07 20:48:25 +00:00
|
|
|
if (Array.isArray(val)) {
|
|
|
|
return { dirs: val }
|
2021-11-19 12:22:27 +00:00
|
|
|
}
|
|
|
|
if (val === undefined || val === true) {
|
|
|
|
return { dirs: ['~/components'] }
|
|
|
|
}
|
|
|
|
return val
|
|
|
|
}
|
|
|
|
},
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Configure how Nuxt auto-imports composables into your application.
|
|
|
|
*
|
2022-04-12 09:59:32 +00:00
|
|
|
* @see [Nuxt 3 documentation](https://v3.nuxtjs.org/guide/directory-structure/composables)
|
2021-11-19 12:22:27 +00:00
|
|
|
* @type {typeof import('../src/types/imports').AutoImportsOptions}
|
2022-03-22 17:04:31 +00:00
|
|
|
* @version 3
|
2021-11-19 12:22:27 +00:00
|
|
|
*/
|
|
|
|
autoImports: {
|
|
|
|
global: false,
|
|
|
|
dirs: []
|
|
|
|
},
|
|
|
|
}
|