@@ -167,12 +167,10 @@ function linkManPages(text) {
167167 const displayAs = `<code>${ name } (${ number } ${ optionalCharacter } )</code>` ;
168168
169169 if ( BSD_ONLY_SYSCALLS . has ( name ) ) {
170- return `${ beginning } <a href="https://www.freebsd.org/cgi/man.cgi` +
171- `?query=${ name } &sektion=${ number } ">${ displayAs } </a>` ;
170+ return `${ beginning } <a href="https://www.freebsd.org/cgi/man.cgi?query=${ name } &sektion=${ number } ">${ displayAs } </a>` ;
172171 }
173172
174- return `${ beginning } <a href="http://man7.org/linux/man-pages/man${ number } ` +
175- `/${ name } .${ number } ${ optionalCharacter } .html">${ displayAs } </a>` ;
173+ return `${ beginning } <a href="http://man7.org/linux/man-pages/man${ number } /${ name } .${ number } ${ optionalCharacter } .html">${ displayAs } </a>` ;
176174 } ) ;
177175}
178176
@@ -210,17 +208,14 @@ export function preprocessElements({ filename }) {
210208 } else if ( node . type === 'code' ) {
211209 if ( ! node . lang ) {
212210 console . warn (
213- `No language set in ${ filename } , ` +
214- `line ${ node . position . start . line } ` ) ;
211+ `No language set in ${ filename } , line ${ node . position . start . line } `
212+ ) ;
215213 }
216214 const className = isJSFlavorSnippet ( node ) ?
217215 `language-js ${ node . lang } ` :
218216 `language-${ node . lang } ` ;
219217 const highlighted =
220- `<code class='${ className } '>` +
221- ( getLanguage ( node . lang || '' ) ?
222- highlight ( node . value , { language : node . lang } ) : node ) . value +
223- '</code>' ;
218+ `<code class='${ className } '>${ ( getLanguage ( node . lang || '' ) ? highlight ( node . value , { language : node . lang } ) : node ) . value } </code>` ;
224219 node . type = 'html' ;
225220
226221 if ( isJSFlavorSnippet ( node ) ) {
@@ -354,8 +349,7 @@ function parseYAML(text) {
354349
355350 result += '</table>\n</details>\n' ;
356351 } else {
357- result += `${ added . description } ${ deprecated . description } ` +
358- `${ removed . description } \n` ;
352+ result += `${ added . description } ${ deprecated . description } ${ removed . description } \n` ;
359353 }
360354
361355 if ( meta . napiVersion ) {
@@ -418,15 +412,14 @@ export function buildToc({ filename, apilinks }) {
418412 const hasStability = node . stability !== undefined ;
419413 toc += ' ' . repeat ( ( depth - 1 ) * 2 ) +
420414 ( hasStability ? `* <span class="stability_${ node . stability } ">` : '* ' ) +
421- `<a href="#${ isDeprecationHeading ? node . data . hProperties . id : id } ">` +
422- `${ headingText } </a>${ hasStability ? '</span>' : '' } \n` ;
415+ `<a href="#${ isDeprecationHeading ? node . data . hProperties . id : id } ">${ headingText } </a>${ hasStability ? '</span>' : '' } \n` ;
423416
424417 let anchor =
425418 `<span><a class="mark" href="#${ id } " id="${ id } ">#</a></span>` ;
426419
427420 if ( realFilename === 'errors' && headingText . startsWith ( 'ERR_' ) ) {
428- anchor += `<span><a class="mark" href="# ${ headingText } " ` +
429- ` id="${ headingText } ">#</a></span>`;
421+ anchor +=
422+ `<span><a class="mark" href="# ${ headingText } " id="${ headingText } ">#</a></span>`;
430423 }
431424
432425 const api = headingText . replace ( / ^ .* : \s + / , '' ) . replace ( / \( .* / , '' ) ;
@@ -476,8 +469,7 @@ function altDocs(filename, docCreated, versions) {
476469 `${ host } /docs/latest-v${ versionNum } /api/${ filename } .html` ;
477470
478471 const wrapInListItem = ( version ) =>
479- `<li><a href="${ getHref ( version . num ) } ">${ version . num } ` +
480- `${ version . lts ? ' <b>LTS</b>' : '' } </a></li>` ;
472+ `<li><a href="${ getHref ( version . num ) } ">${ version . num } ${ version . lts ? ' <b>LTS</b>' : '' } </a></li>` ;
481473
482474 function isDocInVersion ( version ) {
483475 const [ versionMajor , versionMinor ] = version . num . split ( '.' ) . map ( Number ) ;
0 commit comments