如何在Jade表数据元素中使用内联CSS?

如何在Jade表数据元素中使用内联CSS?,css,node.js,pug,Css,Node.js,Pug,如何将表数据元素设置为jade中的特定字体颜色?td将从数据库获取和呈现数据 table.table.table-striped#dashboardTable(style="width:100%") thead tr th(style='width:15px') Account# th(style='width:65px') AccountNickName th(s

如何将表数据元素设置为jade中的特定字体颜色?
td
将从数据库获取和呈现数据

table.table.table-striped#dashboardTable(style="width:100%")
          thead
            tr 
              th(style='width:15px') Account#
              th(style='width:65px') AccountNickName 
              th(style='width:5px') AccountOwner
          tbody
            for each in usersDocs
              tr
              span(style='color:orange')
                td #{each._id}
              td #{each.email}
              td #{each.firstName}

style=color:orange
不起作用。我一刷新页面,它就开始工作,但正在恢复为黑色,这是我的style.css文件中的默认链接颜色。

这将对您有所帮助

  table.table.table-striped#dashboardTable(style="width:100%")
      thead
        tr 
          th(style='width:15px') Account#
          th(style='width:65px') AccountNickName 
          th(style='width:5px') AccountOwner
      tbody
        for each in usersDocs
          tr.tabledata(style='color:red')  <!--here you can specify your color code or class name-->           
            td
              span(style='color:orange') #{each._id}
            td #{each.email}
            td #{each.firstName}
table.table.table条带化#仪表板表格(style=“width:100%”)
泰德
tr
th(style='width:15px')帐户#
th(style='width:65px')帐户昵称
th(style='width:5px')帐户所有者
表格主体
对于usersDocs中的每个
tr.tabledata(style='color:red')
运输署
span(style='color:orange')#{each._id}
td{each.email}
td#{每个名字}