Code Monkey home page Code Monkey logo

Comments (7)

amekusa avatar amekusa commented on August 16, 2024

Hi :) Thank you for reporting the issue.
I tested the following code with the JSDoc's default theme to see if @modifies tag is rendered correctly.

/**
 * Test Class
 */
class TestClass {
	/**
	 * Test Function
	 * @modifies {unread} The unread count is updated
	 */
	async function_name() {}
}

Because the base logic in Docolatte's HTML generation (data parsing, templating, etc.) is mostly derived from the JSDoc's default theme, if there is a bug in the default theme, Docolatte might also have the same issue.

And this is the result (default theme):
Screen Shot 2024-03-29 at 12 43 47 PM

So, I see the same issue in the default theme (missing description).

I guess, maybe this is a templating problem. Let me see if I can fix this.

from docolatte.

amekusa avatar amekusa commented on August 16, 2024

So, I fixed the template so it can show description of @modifies tag.
This is the rendering result:
Screen Shot 2024-03-29 at 2 15 26 PM

This is the code:

/**
 * Test Class
 */
class TestClass {

	/**
	 * Test Function with type and description
	 * @modifies {unread} The unread count is updated
	 */
	async function_name1() {}

	/**
	 * Test Function with type only
	 * @modifies {Number}
	 */
	async function_name2() {}

	/**
	 * Test Function with description only
	 * @modifies The unread count is updated
	 */
	async function_name3() {}

	/**
	 * Test Function with multiple types
	 * @modifies {unread|Number} The unread count is updated
	 */
	async function_name4() {}
}

You can test the fix I just pushed on dev branch. Maybe just copy & paste from the commit log above is faster.

from docolatte.

amekusa avatar amekusa commented on August 16, 2024

@albadedan If you are good with the fix, I merge it into master and publish it to npm.

from docolatte.

albadedan avatar albadedan commented on August 16, 2024

from docolatte.

amekusa avatar amekusa commented on August 16, 2024

Just published v4.5.1 with the fix.
I'm also working on more improvements like foldable menu items.
Thank you for your positive feedback, which motivates me a lot!

from docolatte.

albadedan avatar albadedan commented on August 16, 2024

Just tried this and it all works perfectly, thank you.

Foldable menu items does sound good, I do have a few very large tables and things.
Would be good if there was a global setting to default foldable items to open or closed, but then also override at the comment level for a specific item. Not critical by any means, but would be nice.

Also, unrelated, docolatte is the only theme I've found that worked perfectly with jsdoc-vuejs out of the box. All the other themes I tried seemed to require tedious setup, or had dependency issues.

from docolatte.

amekusa avatar amekusa commented on August 16, 2024

hmm, I've never tried jsdoc-vuejs but, maybe the reason docolatte works well with it is, I try not to change the code derived from JSDoc's default theme as much as I can, so it works exact same as the default theme at a basic level.

About foldable menu items that I'm trying to implement, yes, it should be able to specify the default (or completely turn off) with option.
Not sure if it would/should be able to override at the comment level, since it is purely presentational feature.
But maybe, would be nice if we also can specify which items are/aren't folded with option.

But anyway, I appreciate your feed back!

from docolatte.

Related Issues (4)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.