question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Failed to execute 'appendChild' on 'Node': This node type does not support this method.

See original GitHub issue
  • I confirm that this is an issue rather than a question.

Bug report

Steps to reproduce

What is expected?

What is actually happening?

Other relevant information

  • Output of npx vuepress info in my VuePress project:

When I develop my docs in development environment, it is ok. When i build it and put it on my server with nginx, it is also ok. However when i refresh the page with routes like this http://xxx.com/develop It has the error below image

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:13
  • Comments:29 (2 by maintainers)

github_iconTop GitHub Comments

8reactions
mashpiecommented, May 22, 2020

Just a hint: Another common mistake is to use dynamic vue components that should render client side but forget to ignore them in static builds… 99% of those issues in our projects were missing <ClientOnly>. So try:

<ClientOnly>
  <NonSSRFriendlyComponent/>
</ClientOnly>

and read https://vuepress.vuejs.org/guide/using-vue.html

2reactions
hugojingcommented, Aug 19, 2019

I had the same problem, and then I found out it had to do with document

enhanceApp.js

  if (typeof window !== 'undefined') { // add this line
    window.document.xxx
  }

I have no enhanceApp.js file and no nginx, but still have this issue.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Failed to execute 'appendChild' on 'Node': This node type ...
I've tracked it down the error ( Failed to execute 'appendChild' on 'Node' ) to occur when the first children of a page...
Read more >
nuxt js "Failed to execute 'appendChild' on 'Node'
DOMException: Failed to execute 'appendChild' on 'Node': This node type does not support this method. both errors occur in the same scenario.
Read more >
DOMException: Failed to execute 'appendChild' on 'Node'
DOMException: Failed to execute 'appendChild' on 'Node': This node type does not support this method. I have this error only on mobile, Any ......
Read more >
DOMException: Failed to execute 'appendChild' on 'Node'
DOMException: Failed to execute 'appendChild' on 'Node': This node type does not support this method. The error is caused 100% by the form...
Read more >
Failed to execute 'appendChild' on 'Node'
Failed to execute 'appendChild' on 'Node': This node type does not support this method.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found