網站首頁 編程語言 正文
nuxt 打包后運行 DOMException: Failed to execute ‘appendChild‘ on ‘Node‘: This node(已解決)
作者:lllomh 更新時間: 2022-02-28 編程語言開發環境有這個錯誤的話:不影響使用:不管的話?
一般在開發環境下,日志會有
warning:The client-side rendered virtual DOM tree is not matching server-rendered content. This is likely caused by incorrect HTML markup, for example nesting block-level elements inside <p>, or missing <tbody>. Bailing hydration and performing full client-side render.
但是不影響使用,而且一般都是在刷新當前頁面的時候才會報這個警告。但是一旦build發布到線上就會發生
DOMException: Failed to execute 'appendChild' on 'Node': This node type does not support this method
的問題。
我的解決方案是,直接在疑似產生The client-side rendered virtual DOM tree is not matching server-rendered content
問題的代碼上包裹一層<client-only>
標簽,直接不讓后臺渲染這部分代碼就解決這個問題了
原文鏈接:https://blog.csdn.net/lllomh/article/details/123072753
相關推薦
- 2022-01-04 微信小程序內部A頁面向內嵌H5頁面跳轉,并且傳參
- 2022-09-06 .net6?使用Senparc開發小程序配置過程_實用技巧
- 2023-06-02 Pandas計算元素的數量和頻率的方法(出現的次數)_python
- 2022-11-24 Django?ORM?F對象和Q對象查詢_python
- 2022-11-20 解析在Tomcat中啟用虛擬線程特性_Tomcat
- 2022-05-20 springCloud_Feign遠程調用
- 2022-08-17 C++關于樹的定義全面梳理_C 語言
- 2022-05-16 Qt5中QML自定義環形菜單/環形選擇框的實現_C 語言
- 最近更新
-
- window11 系統安裝 yarn
- 超詳細win安裝深度學習環境2025年最新版(
- Linux 中運行的top命令 怎么退出?
- MySQL 中decimal 的用法? 存儲小
- get 、set 、toString 方法的使
- @Resource和 @Autowired注解
- Java基礎操作-- 運算符,流程控制 Flo
- 1. Int 和Integer 的區別,Jav
- spring @retryable不生效的一種
- Spring Security之認證信息的處理
- Spring Security之認證過濾器
- Spring Security概述快速入門
- Spring Security之配置體系
- 【SpringBoot】SpringCache
- Spring Security之基于方法配置權
- redisson分布式鎖中waittime的設
- maven:解決release錯誤:Artif
- restTemplate使用總結
- Spring Security之安全異常處理
- MybatisPlus優雅實現加密?
- Spring ioc容器與Bean的生命周期。
- 【探索SpringCloud】服務發現-Nac
- Spring Security之基于HttpR
- Redis 底層數據結構-簡單動態字符串(SD
- arthas操作spring被代理目標對象命令
- Spring中的單例模式應用詳解
- 聊聊消息隊列,發送消息的4種方式
- bootspring第三方資源配置管理
- GIT同步修改后的遠程分支