Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deployment Error #949

Closed
JK-Effects opened this issue Jul 15, 2023 · 6 comments · Fixed by #961
Closed

Deployment Error #949

JK-Effects opened this issue Jul 15, 2023 · 6 comments · Fixed by #961

Comments

@JK-Effects
Copy link

JK-Effects commented Jul 15, 2023

Deploying the App delivers an error called this.docs.forEach is not a function.
By downgrading the nuxt version I got more debugging messages and I dicovered this is due to the AppSearch element in the navbar.

Removing the AppSearch Component in the \node_modules\@nuxt-themes\docus\components\app\AppHeader.vue solves this error.

...
<div class="section right">
 <!-- <AppSearch />  <- remove this part-->
  <ThemeSelect />
  <div class="social-icons">
    <AppSocialIcons />
  </div>
</div>
...

I don't know why this component is broken. In dev-mode it works totally fine.

Quick fix: Optionally, the component can also be copied to the components directory on the project root using the same name.
If the components directory is global, the AppHeader will be overwritten.
Note that you must remove the AppSearch from the newly created component.

image

Copy link
Contributor

Atinux commented Jul 17, 2023

Mind looking at it @bdrtsky ?

@squpshift
Copy link

+1

1 similar comment
@aburii
Copy link

aburii commented Jul 26, 2023

+1

@bdrtsky
Copy link
Contributor

bdrtsky commented Jul 26, 2023

How you deploying it? Local build seems to work.

@codebykenny
Copy link
Contributor

codebykenny commented Jul 26, 2023

Steps to reproduce brand new project:

npx nuxi@latest init docs -t themes/docus 
cd docs
npm install
npm run build
node .output/server/index.mjs

Kenny- 2023-07-26 at 12 50 02

@JK-Effects
Copy link
Author

package.json

"devDependencies": {
    "@nuxt-themes/docus": "^1.13.1",
    "@nuxt/devtools": "^0.6.7",
    "@nuxt/eslint-config": "^0.1.1",
    "@nuxtjs/plausible": "^0.2.1",
    "@types/node": "^20.4.0",
    "eslint": "^8.44.0",
    "nuxt": "^3.6.2"
  },

Just depoly it with npm run build (nuxi build)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants