File tree Expand file tree Collapse file tree 4 files changed +10
-10
lines changed Expand file tree Collapse file tree 4 files changed +10
-10
lines changed Original file line number Diff line number Diff line change @@ -408,11 +408,11 @@ var Search = {
408408 ( async ( ) => {
409409 const pagefindURL =
410410 `${ baseURLPrefix } pagefind/pagefind.js`
411- // adjust the `baseURLPrefix` if it is relative: the `import`
412- // is relative to the _script URL_ here, which is in /js/.
413- // That is different from other uses of `baseURLPrefix`, which
414- // replace `href` and `src` attributes which are relative to the
415- // page itself that is outside of /js/.
411+ // adjust the `baseURLPrefix` if it is relative: the `import`
412+ // is relative to the _script URL_ here, which is in /js/.
413+ // That is different from other uses of `baseURLPrefix`, which
414+ // replace `href` and `src` attributes which are relative to the
415+ // page itself that is outside of /js/.
416416 . replace ( / ^ \. \/ / , '../' )
417417 Search . pagefind = await import ( pagefindURL ) ;
418418 const options = {
Original file line number Diff line number Diff line change @@ -64,8 +64,8 @@ <h1>Redirecting…</h1>
6464
6565 < link href ="{{ relURL "favicon.ico " }}" rel='shortcut icon ' type ='image/x-icon '>
6666
67- {{ $style := resources.Get "sass/application.scss" | resources.ExecuteAsTemplate "application.scss" . | css.Sass | resources.Minify }}
68- < link rel ="stylesheet " href ="{{ $style.RelPermalink }} ">
67+ {{ $style := resources.Get "sass/application.scss" | resources.ExecuteAsTemplate "application.scss" . | css.Sass | resources.Minify | fingerprint }}
68+ < link rel ="stylesheet " href ="{{ $style.RelPermalink }} "{{ if (hasPrefix .Site.BaseURL "https://") }} integrity=" {{ $style.Data.Integrity }} " {{ end }} >
6969 <!--[if (gte IE 6)&(lte IE 8)]>
7070 <script src="{{ relURL "js/selectivizr-min.js" }}"></script>
7171 <![endif]-->
Original file line number Diff line number Diff line change 1818< script src ="{{ relURL "js /modernizr.js" }}"> </ script >
1919< script src ="{{ relURL "js /modernize.js" }}"> </ script >
2020{{ if eq (.Scratch.Get "section") "search" }}< script src ="{{ relURL "pagefind /pagefind-ui.js" }}"> </ script > {{ end }}
21- {{ $js := resources.Get "js/application.js" | resources.ExecuteAsTemplate "js/application.js" . | resources.Minify }}
22- < script src ="{{ $js.RelPermalink }} "> </ script >
21+ {{ $js := resources.Get "js/application.js" | resources.ExecuteAsTemplate "js/application.js" . | resources.Minify | fingerprint }}
22+ < script src ="{{ $js.RelPermalink }} "{{ if (hasPrefix .Site.BaseURL "https://") }} integrity=" {{ $js.Data.Integrity }} " {{ end }} > </ script >
Original file line number Diff line number Diff line change @@ -254,7 +254,7 @@ test('404', async ({ page }) => {
254254 await expect ( page . locator ( '.inner h1' ) ) . toHaveText ( `That page doesn't exist.` )
255255
256256 // the 404 page should be styled
257- await expect ( page . locator ( 'link[rel="stylesheet"]' ) ) . toHaveAttribute ( 'href' , / a p p l i c a t i o n ( \. m i n ) ? \. c s s $ / )
257+ await expect ( page . locator ( 'link[rel="stylesheet"]' ) ) . toHaveAttribute ( 'href' , / a p p l i c a t i o n ( \. m i n ) ? ( \. [ 0 - 9 a - f ] + ) ? \. c s s $ / )
258258
259259 // the search box is shown
260260 await expect ( page . locator ( '#search-text' ) ) . toBeVisible ( )
You can’t perform that action at this time.
0 commit comments