你需要设置CSS的overflow属性为hidden,以隐藏溢出的内容;同时设置text-overflow属性为ellipsis,以便在内容溢出时用省略号表示。 确保元素具有适当的宽度限制: 为了使溢出隐藏效果生效,你需要确保el-menu-item具有一个明确的宽度限制。如果el-menu-item的宽度是自适应的,那么溢出隐藏效果可能无法正确触发。 下面是一个示例...
When the mode attribute of the component is set to horizontal and ellipsis is set to true by default, changing the window size will cause the vue to throw an infinite loop warning, causing the browser to get stuck,Source code location that triggered the warning...