File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 3535 fetch-depth : 1
3636
3737 - name : Setup Pages
38+ id : pages
3839 uses : actions/configure-pages@v5
3940
4041 - name : Cache JS dependencies
@@ -59,13 +60,13 @@ jobs:
5960 run : |
6061 cd portal
6162 npm ci
62- npm run build
6363
6464 - name : Build static website
65+ env :
66+ ASSETS_URL : ${{ steps.pages.outputs.base_url }}
6567 run : |
6668 cd portal
6769 npm run build
68- vendor/bin/jigsaw build production
6970
7071
7172 - name : Upload artifact
Original file line number Diff line number Diff line change 11<?php
22
3+ use Illuminate \Support \Str ;
4+
35return [
46 'production ' => false ,
57 'baseUrl ' => 'http://localhost:8000/ ' ,
2123 },
2224 ],
2325 ],
26+
27+ 'absoluteUrl ' => function ($ page , $ path ) {
28+ if (Str::startsWith ($ path , 'http ' )){
29+ return $ path ;
30+ }
31+
32+ return rtrim ($ page ->baseUrl , '/ ' ) . '/ ' . trimPath ($ path );
33+ },
2434];
Original file line number Diff line number Diff line change 1010 <link rel =" stylesheet" href =" {{ vite (' source/_assets/css/main.css' ) } }" >
1111 <script defer type =" module" src =" {{ vite (' source/_assets/js/main.js' ) } }" ></script >
1212
13- <link rel =" icon" type =" image/svg+xml" href =" /assets/favicon.svg" >
13+ <link rel =" icon" type =" image/svg+xml" href =" {{ $page -> absoluteUrl ( ' /assets/favicon.svg' ) } } " >
1414
1515
1616 <meta property =" og:title" content =" {{ $page -> title } }" >
2020 <link rel =" canonical" href =" {{ $page -> getUrl () } }" >
2121 <meta property =" og:url" content =" {{ $page -> getUrl () } }" >
2222 <meta property =" og:site_name" content =" OneOffTech" >
23- <meta property =" og:image" content =" /assets/images/og.jpg" >
23+ <meta property =" og:image" content =" {{ $page -> absoluteUrl ( ' /assets/images/og.jpg' ) } } " >
2424 <meta property =" og:type" content =" website" >
2525 <meta name =" twitter:card" content =" summary_large_image" >
26- <meta property =" twitter:image" content =" /assets/images/og.jpg" >
26+ <meta property =" twitter:image" content =" {{ $page -> absoluteUrl ( ' /assets/images/og.jpg' ) } } " >
2727 <meta property =" twitter:title" content =" {{ $page -> title } }" >
2828
2929
You can’t perform that action at this time.
0 commit comments