cwilson1031 / jsdoc-toolkit

Automatically exported from code.google.com/p/jsdoc-toolkit
0 stars 0 forks source link

Trying to add a class #324

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
I want to add a class on this ul tag (in the for Loop):

<p class="inheritsList">
 {!
var borrowedMembers = data.methods.filter(function($) {return $.memberOf != 
data.alias});
var contributers = [];
borrowedMembers.map(function($) {if (contributers.indexOf($.memberOf) < 0) 
contributers.push($.memberOf)});
    for (var i = 0, l = contributers.length; i < l; i++) {
        output +=
        "<p>Methods borrowed from class "+new Link().toSymbol(contributers[i])+": </p>"
        +
        "<ul class="list_borrow">" +
            borrowedMembers
            .filter(function($) { return $.memberOf == contributers[i] })
            .sort(makeSortby("name"))
            .map(function($) { return new Link().toSymbol($.alias).withText($.name) })
            +
            "</ul>";
    }

!}
</p>

But this : ... "<ul class="list_borrow">" + ... don't seems to be the right 
syntax.

Sorry but I'm a beginner...

What version of the product are you using? On what operating system?
jsdoc_toolkit-2.4.0 
Windows XP

Please provide any additional information below.
I'm french, sorry for the mistakes. Thanks for your understanding

Original issue reported on code.google.com by florence...@gmail.com on 13 Jul 2011 at 11:28

GoogleCodeExporter commented 8 years ago
In case you haven't already figured this out since July, having quotes inside 
of quotes like that won't work. I presume you currently get a syntax error in 
the console or something stranger. You need to use single quotes around the 
class attribute value or escape the double quotes.

Like
"<ul class='list_borrow'>"
or
"<ul class=\"list_borrow\">"

Original comment by mcbain....@gmail.com on 3 Jan 2012 at 10:02