Documenting arrays in JSDoc typedefs for VS Intellisense
<p>In my VS2015 JavaScript app, I have a JSON object that I get from a REST API that I have documented using JSDoc <code>@typedef</code> comments:</p>

<pre><code>/**
 * @typedef {Object} JSON_Response
 * @property {Number} id
 * @property {String} name
 * @property {JSON_Response_Tag} tag
 */

/**
 * @typedef {Object} JSON_Response_Tag
 * @property {Number} id
 * @property {String} color
 */
</code></pre>

<p>When I reference this type in JSDoc comments on the methods that consume these JSON objects, I can get Intellisense documentation just fine:</p>

<pre><code>/**
 * @param {JSON_Response} response
 */
function process_response(response) {
  // process response here...
}
</code></pre>

<p>However, I simply cannot get this to work with arrays - when I attempt to index the array, I get the "yellow triangles" menu that happens when VS can't get Intellisense context for you:</p>

<pre><code>/**
 * @typedef {Object} JSON_Response
 * @property {Number} id
 * @property {String} name
 * @property {JSON_Response_Tag[]} tags
 */

/**
 * @param {JSON_Response} response
 */
function process_response(response) {
  response.tags[0]. // no intellisense here
}
</code></pre>

<p>JSDoc's other recommended method, using <a href="http://usejsdoc.org/tags-type.html" rel="noreferrer"><code>{Array.&lt;JSON_Response&gt;}</code></a>, informs VS that <code>response</code> is an Array but does not give Intellisense for anything under that. Microsoft's own XML comments do provide this capability, but only for function parameters - I can't reach inside the objects, nor would I like to do so because I'd have to add this documentation every time the function is called.</p>

<p>Is there any way to document arrays with their underlying types in JavaScript's VS Intellisense?</p>

<p>If I have to write code, I want to minimize the side effects / be able to factor it out of the release.</p>