Skip to content

Commit

Permalink
fix: use full resolved paths in nuxt.config
Browse files Browse the repository at this point in the history
Signed-off-by: ZTL-UwU <[email protected]>
  • Loading branch information
ZTL-UwU committed Jul 27, 2024
1 parent 741c231 commit 1edad9d
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 14 deletions.
10 changes: 9 additions & 1 deletion content/1.getting-started/4.changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,15 @@ title: Changelog
description: Changes made to shadcn-docs.
---

## `0.4.2`
## `v0.4.3`

#### :icon{name="lucide:bug"} Fixes

- Place aside in app.vue to avoid navigation shifts.
- **mobile**: Close sheet on navigation.
- Use full resolved paths in `nuxt.config`.

## `v0.4.2`

- Use page title for breadcrumb path.

Expand Down
2 changes: 1 addition & 1 deletion content/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ navigation: false
::hero
---
announcement:
title: 'Release v0.4.2'
title: 'Release v0.4.3'
icon: 'noto:party-popper'
to: /getting-started/changelog
actions:
Expand Down
22 changes: 12 additions & 10 deletions nuxt.config.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// https://nuxt.com/docs/api/configuration/nuxt-config
import { fileURLToPath } from 'node:url';
import { dirname, join } from 'node:path';

const currentDir = dirname(fileURLToPath(import.meta.url));

export default defineNuxtConfig({
devtools: { enabled: true },
modules: [
Expand All @@ -11,15 +15,8 @@ export default defineNuxtConfig({
'@nuxtjs/color-mode',
],
shadcn: {
/**
* Prefix for all the imported component
*/
prefix: 'Ui',
/**
* Directory that the component lives in.
* @default "./components/ui"
*/
componentDir: './components/ui',
componentDir: join(currentDir, './components/ui'),
},
components: {
dirs: [
Expand All @@ -32,7 +29,12 @@ export default defineNuxtConfig({
colorMode: {
classSuffix: '',
},
css: ['@/assets/css/themes.css'],
tailwindcss: {
cssPath: join(currentDir, './assets/css/tailwind.css'),
},
css: [
join(currentDir, './assets/css/themes.css'),
],
content: {
documentDriven: true,
highlight: {
Expand Down
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "shadcn-docs-nuxt",
"type": "module",
"version": "0.4.2",
"version": "0.4.3",
"author": "Tony Zhang <[email protected]>",
"license": "MIT",
"homepage": "https://shadcn-docs.nuxt.dev/",
Expand All @@ -14,13 +14,15 @@
"files": [
"app",
"app.vue",
"assets",
"components",
"components.json",
"composables",
"layouts",
"lib",
"nuxt.config.ts",
"pages"
"pages",
"types"
],
"scripts": {
"build": "nuxt build",
Expand Down

0 comments on commit 1edad9d

Please sign in to comment.