How to write jade template id as a variable

topic description

sources of topics and their own ideas

personal blog reading statistics when leancloud was introduced, most of the templates found in the tutorials used ejs, but the subject used jade. As they are not familiar with Jade, all have this doubt. Thank you for your help

related codes

/ / Please paste the code text below (do not replace the code with pictures)
how to convert ejs code to Jade code

<% if (theme.leancloud_visitors.enable) { %>
    <span id="<%- url_for(item.path) %>" class="leancloud_visitors" data-title="<%= item.title %>"></span>
<% } %>

what result do you expect? What is the error message actually seen?

rewrite into Jade code

Apr.09,2022

<% if (theme.leancloud_visitors.enable) { %>
    span-sharp<%- url_for(item.path) %>.leancloud_visitors(data-title="<%= item.title %>")
<% } %>

basic principles of Jade

span-sharp{id}.{class}()
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1ea62aa-1db5.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1ea62aa-1db5.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?