setAttribute("class", "current")
发布于 9 年前 作者 mmXiaoYao 3106 次浏览 最后一次编辑是 8 年前 来自 问答

请问juery中setAttribute(“class”, “current”)和$!{rootPath}index怎么理解?

5 回复

那个{root Path}不像是jquery里的。像是模版里的变量替换

setAttribute 是该html node的attribute。多看看文档

@leapon恩,好谢谢阿

@leapon 对,rootPath是自定义变量,想问一下index写在大括号{}外面代表什么意思呢~

@mmXiaoYao 贴一下上下文吧。估计用了某个template engine。要结合起来才能看明白。

回到顶部