@@ -71,7 +71,7 @@ module.exports = function (eleventyConfig) {
7171
7272 eleventyConfig . addWatchTarget ( '../lit-dev-api/api-data/*/*.json' ) ;
7373 eleventyConfig . addWatchTarget (
74- '../lit-dev-content/samples/tutorials/**/tutorial.json'
74+ '../lit-dev-content/samples/tutorials/**/tutorial.json' ,
7575 ) ;
7676 eleventyConfig . addWatchTarget ( '../lit-dev-content/samples/tutorials/**/*.md' ) ;
7777 eleventyConfig . addWatchTarget ( '../lit-dev-content/rollupout/server/*' ) ;
@@ -119,14 +119,14 @@ ${content}
119119 Object . assign ( new state . Token ( 'div_open' , 'div' , 1 ) , {
120120 attrs : [ [ 'class' , `heading ${ headingTag } ` ] ] ,
121121 block : true ,
122- } )
122+ } ) ,
123123 ) ;
124124 state . tokens . splice (
125125 idx + 4 ,
126126 0 ,
127127 Object . assign ( new state . Token ( 'div_close' , 'div' , - 1 ) , {
128128 block : true ,
129- } )
129+ } ) ,
130130 ) ;
131131 linkAfterHeaderBase ( slug , opts , state , idx + 1 ) ;
132132 } ;
@@ -165,16 +165,16 @@ ${content}
165165 function ( url , latestVersion ) {
166166 if ( ! latestVersion ) {
167167 throw new Error (
168- `No latestVersion provided to 'removeLatestVersionFromUrl`
168+ `No latestVersion provided to 'removeLatestVersionFromUrl` ,
169169 ) ;
170170 }
171171 if ( ! url . includes ( `/${ latestVersion } /` ) ) {
172172 throw new Error (
173- `'${ url } ' does not include the latestVersion versioned path segment`
173+ `'${ url } ' does not include the latestVersion versioned path segment` ,
174174 ) ;
175175 }
176176 return url . replace ( `/${ latestVersion } /` , '/' ) ;
177- }
177+ } ,
178178 ) ;
179179
180180 /**
@@ -191,11 +191,11 @@ ${content}
191191 }
192192 if ( ! latestVersion ) {
193193 throw new Error (
194- `latestVersion not provided to 'fixUnversionedCrossLinks`
194+ `latestVersion not provided to 'fixUnversionedCrossLinks` ,
195195 ) ;
196196 }
197197 return content . replaceAll ( `/docs/${ latestVersion } /` , '/docs/' ) ;
198- }
198+ } ,
199199 ) ;
200200
201201 eleventyConfig . addFilter ( 'removeExtension' , function ( url ) {
@@ -446,7 +446,7 @@ ${content}
446446 if ( location === undefined ) {
447447 throw new Error (
448448 `Ambiguous symbol ${ symbol } . ` +
449- `Options: ${ locations . map ( ( l ) => l . anchor ) . join ( ', ' ) } `
449+ `Options: ${ locations . map ( ( l ) => l . anchor ) . join ( ', ' ) } ` ,
450450 ) ;
451451 }
452452
@@ -459,17 +459,17 @@ ${content}
459459 'api-v3' ,
460460 '/docs/v3/api' ,
461461 JSON . parse (
462- fsSync . readFileSync ( '../lit-dev-api/api-data/lit-3/symbols.json' , 'utf8' )
463- )
462+ fsSync . readFileSync ( '../lit-dev-api/api-data/lit-3/symbols.json' , 'utf8' ) ,
463+ ) ,
464464 ) ;
465465
466466 addApiShortcode (
467467 'api' ,
468468 '/docs/v2/api' ,
469469 // Don't use require() because of Node caching in watch mode.
470470 JSON . parse (
471- fsSync . readFileSync ( '../lit-dev-api/api-data/lit-2/symbols.json' , 'utf8' )
472- )
471+ fsSync . readFileSync ( '../lit-dev-api/api-data/lit-2/symbols.json' , 'utf8' ) ,
472+ ) ,
473473 ) ;
474474
475475 addApiShortcode (
@@ -478,9 +478,9 @@ ${content}
478478 JSON . parse (
479479 fsSync . readFileSync (
480480 '../lit-dev-api/api-data/lit-html-1/symbols.json' ,
481- 'utf8'
482- )
483- )
481+ 'utf8' ,
482+ ) ,
483+ ) ,
484484 ) ;
485485
486486 addApiShortcode (
@@ -489,9 +489,9 @@ ${content}
489489 JSON . parse (
490490 fsSync . readFileSync (
491491 '../lit-dev-api/api-data/lit-element-2/symbols.json' ,
492- 'utf8'
493- )
494- )
492+ 'utf8' ,
493+ ) ,
494+ ) ,
495495 ) ;
496496
497497 /**
@@ -520,7 +520,7 @@ ${content}
520520 `CleanCSS errors/warnings on file ${ path } :\n\n${ [
521521 ...result . errors ,
522522 ...result . warnings ,
523- ] . join ( '\n' ) } `
523+ ] . join ( '\n' ) } `,
524524 ) ;
525525 }
526526 return `<style>${ result . styles } </style>` ;
@@ -554,14 +554,14 @@ ${content}
554554 // Source: https://github.com/11ty/eleventy-base-blog/blob/master/.eleventy.js
555555 eleventyConfig . addFilter ( 'readableDate' , ( dateObj ) => {
556556 return luxon . DateTime . fromJSDate ( dateObj , { zone : 'utc' } ) . toFormat (
557- 'LLL d, yyyy'
557+ 'LLL d, yyyy' ,
558558 ) ;
559559 } ) ;
560560
561561 // https://html.spec.whatwg.org/multipage/common-microsyntaxes.html#valid-date-string
562562 eleventyConfig . addFilter ( 'yyyymmdd' , ( dateObj ) => {
563563 return luxon . DateTime . fromJSDate ( dateObj , { zone : 'utc' } ) . toFormat (
564- 'yyyy-LL-dd'
564+ 'yyyy-LL-dd' ,
565565 ) ;
566566 } ) ;
567567
@@ -587,15 +587,15 @@ ${content}
587587 ENV . eleventyOutDir + '/docs/v3/introduction.html' ,
588588 ENV . eleventyOutDir + '/docs/v3/*/index.html' ,
589589 ] ,
590- { ignore : ENV . eleventyOutDir + '/docs/(v1|v2|v3)/index.html' }
590+ { ignore : ENV . eleventyOutDir + '/docs/(v1|v2|v3)/index.html' } ,
591591 )
592592 ) . filter (
593593 // TODO(aomarks) This is brittle, we need a way to annotate inside an md
594594 // file that a page shouldn't be generated.
595595 ( file ) =>
596596 ! file . includes ( 'why-lit' ) &&
597597 ! file . includes ( 'getting-started' ) &&
598- ! file . includes ( 'browser-support' )
598+ ! file . includes ( 'browser-support' ) ,
599599 ) ;
600600 await Promise . all ( emptyDocsIndexFiles . map ( ( path ) => fs . unlink ( path ) ) ) ;
601601
@@ -611,32 +611,32 @@ ${content}
611611 // immediately, instead of triggering an Eleventy build.
612612 await symlinkForce (
613613 path . join ( __dirname , 'site' , 'css' ) ,
614- path . join ( __dirname , ENV . eleventyOutDir , 'css' )
614+ path . join ( __dirname , ENV . eleventyOutDir , 'css' ) ,
615615 ) ;
616616 await symlinkForce (
617617 path . join ( __dirname , 'site' , 'images' ) ,
618- path . join ( __dirname , ENV . eleventyOutDir , 'images' )
618+ path . join ( __dirname , ENV . eleventyOutDir , 'images' ) ,
619619 ) ;
620620 await symlinkForce (
621621 path . join ( __dirname , 'site' , 'fonts' ) ,
622- path . join ( __dirname , ENV . eleventyOutDir , 'fonts' )
622+ path . join ( __dirname , ENV . eleventyOutDir , 'fonts' ) ,
623623 ) ;
624624 await symlinkForce (
625625 path . join ( __dirname , 'samples' ) ,
626- path . join ( __dirname , ENV . eleventyOutDir , 'samples' )
626+ path . join ( __dirname , ENV . eleventyOutDir , 'samples' ) ,
627627 ) ;
628628
629629 // Symlink lib -> _dev/js. This lets us directly reference tsc outputs in
630630 // dev mode, instead of the Rollup bundles we use for production.
631631 await symlinkForce (
632632 path . join ( __dirname , 'lib' ) ,
633- path . join ( __dirname , ENV . eleventyOutDir , 'js' )
633+ path . join ( __dirname , ENV . eleventyOutDir , 'js' ) ,
634634 ) ;
635635 } else {
636636 // Inline all Playground project files directly into their manifests, to
637637 // cut down on requests per project.
638638 await inlinePlaygroundFilesIntoManifests (
639- `${ ENV . eleventyOutDir } /samples/**/project.json`
639+ `${ ENV . eleventyOutDir } /samples/**/project.json` ,
640640 ) ;
641641
642642 // Pre-compress all outputs as .br and .gz files so the server can read
@@ -649,7 +649,7 @@ ${content}
649649 await fs . writeFile (
650650 path . join ( ENV . eleventyOutDir , 'csp-inline-script-hashes.txt' ) ,
651651 [ ...cspInlineScriptHashes ] . join ( '\n' ) ,
652- 'utf8'
652+ 'utf8' ,
653653 ) ;
654654 }
655655 } ) ;
@@ -676,7 +676,7 @@ ${content}
676676 // In prod SSR should use the lit templates run through the minifier.
677677 if ( ! DEV ) {
678678 componentModules = componentModules . map ( ( componentPath ) =>
679- componentPath . replace ( 'lib/components' , 'rollupout/server' )
679+ componentPath . replace ( 'lib/components' , 'rollupout/server' ) ,
680680 ) ;
681681 }
682682
0 commit comments