diff --git a/tools/doc/type-parser.js b/tools/doc/type-parser.js index 38451b0e16b358..0ac15a14b93341 100644 --- a/tools/doc/type-parser.js +++ b/tools/doc/type-parser.js @@ -1,9 +1,8 @@ 'use strict'; const nodeDocUrl = ''; -const jsDocUrl = 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/' + - 'Reference/Global_Objects/'; -const jsPrimitiveUrl = 'https://developer.mozilla.org/en-US/docs/Web/' + - 'JavaScript/Data_structures'; +const jsDocPrefix = 'https://developer.mozilla.org/en-US/docs/Web/JavaScript/'; +const jsDocUrl = jsDocPrefix + 'Reference/Global_Objects/'; +const jsPrimitiveUrl = jsDocPrefix + 'Data_structures'; const jsPrimitives = { 'Integer': 'Number', // this is for extending 'Number': 'Number', @@ -37,6 +36,8 @@ const typeMap = { 'http.IncomingMessage': 'http.html#http_class_http_incomingmessage', 'http.Server': 'http.html#http_class_http_server', 'http.ServerResponse': 'http.html#http_class_http_serverresponse', + 'Iterator': jsDocPrefix + + 'Reference/Iteration_protocols#The_iterator_protocol' }; module.exports = {