Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiline classdesc crashing global index #6

Open
ambischof opened this issue Jul 6, 2016 · 1 comment
Open

Multiline classdesc crashing global index #6

ambischof opened this issue Jul 6, 2016 · 1 comment

Comments

@ambischof
Copy link

Multiline classdesc are not escaped properly and everything after the first linebreak renders after the table.
consider:

/**
 * @class foo
 * @classdesc this is a single line classdesc
 */

/**
 * @class Bar
 * @classdesc
 * this is a
 * multiline
 * class description
 */

/**
 * @class Bizz
 * @classdesc this is a casualty
 */

output:

## Classes
Global | Description
------ | -----------
foo | this is a single line classdesc
Bar | this is a
multiline
class description
Bizz | this is a casualty

## foo
this is a single line classdesc

**Kind**: global class  
## Bar
this is a
multiline
class description

**Kind**: global class  
## Bizz
this is a casualty

**Kind**: global class 

result:

Classes

Global Description
foo this is a single line classdesc
Bar this is a

multiline
class description
Bizz | this is a casualty

foo

this is a single line classdesc

Kind: global class

Bar

this is a
multiline
class description

Kind: global class

Bizz

this is a casualty

Kind: global class


Apart from this issue, I also suggest that if there is a classdesc AND a summary, that the summary is used for the global index instead, since classdesc, like description, may be very long.

@ambischof
Copy link
Author

For what it's worth, I got around it in a fork I made here https://github.com/ambischof/dmd-bitbucket (see change).

I just made it use the summary instead of the classdesc if one was available. (Another workaround would have been just cutting off after the first line but that would have involved helpers and seemed like too much work)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant