Improve loading performance
|
Before Width: | Height: | Size: 146 KiB |
|
After Width: | Height: | Size: 22 KiB |
|
Before Width: | Height: | Size: 17 KiB |
|
After Width: | Height: | Size: 4.1 KiB |
|
Before Width: | Height: | Size: 2.2 KiB |
|
After Width: | Height: | Size: 614 B |
@@ -18,4 +18,4 @@ This is a project that I made as a step in the interview process for my final ye
|
|||||||
|
|
||||||
## Screenshots
|
## Screenshots
|
||||||
|
|
||||||

|

|
||||||
|
Before Width: | Height: | Size: 68 KiB |
|
After Width: | Height: | Size: 13 KiB |
@@ -39,3 +39,20 @@ enableRobotsTXT = true
|
|||||||
name = 'Contact'
|
name = 'Contact'
|
||||||
url = '/contact'
|
url = '/contact'
|
||||||
weight = 5
|
weight = 5
|
||||||
|
[[deployment.matchers]]
|
||||||
|
# Cache static assets for 1 year.
|
||||||
|
pattern = "^.+\\.(js|css|svg|ttf)$"
|
||||||
|
cacheControl = "max-age=31536000, no-transform, public"
|
||||||
|
gzip = true
|
||||||
|
[[deployment.matchers]]
|
||||||
|
pattern = "^.+\\.(gif|png|jpg|webp)$"
|
||||||
|
cacheControl = "max-age=31536000, no-transform, public"
|
||||||
|
gzip = false
|
||||||
|
[[deployment.matchers]]
|
||||||
|
# Set custom content type for /sitemap.xml
|
||||||
|
pattern = "^sitemap\\.xml$"
|
||||||
|
contentType = "application/xml"
|
||||||
|
gzip = true
|
||||||
|
[[deployment.matchers]]
|
||||||
|
pattern = "^.+\\.(html|xml|json)$"
|
||||||
|
gzip = true
|
||||||
|
|||||||
@@ -7,10 +7,10 @@
|
|||||||
{{ define "main" }}
|
{{ define "main" }}
|
||||||
{{ partial "breadcrumb.html" . }}
|
{{ partial "breadcrumb.html" . }}
|
||||||
|
|
||||||
{{ $faceImage := resources.Get "images/big-face.png" }}
|
{{ $faceImage := resources.Get "images/big-face.webp" }}
|
||||||
|
|
||||||
<section>
|
<section>
|
||||||
<img src="{{ $faceImage.Permalink }}" alt="Hazem Krimi's face">
|
<img src="{{ $faceImage.Permalink }}" alt="Hazem Krimi's face" loading="lazy">
|
||||||
{{ .Content }}
|
{{ .Content }}
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
|
|||||||
@@ -4,7 +4,7 @@
|
|||||||
<link rel="stylesheet" href="{{ $styles.Permalink }}" />
|
<link rel="stylesheet" href="{{ $styles.Permalink }}" />
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ define "main" }}
|
{{ define "main" }}
|
||||||
{{ $faceImage := resources.Get "images/big-face.png" }}
|
{{ $faceImage := resources.Get "images/big-face.webp" }}
|
||||||
|
|
||||||
<section id="intro">
|
<section id="intro">
|
||||||
<div>
|
<div>
|
||||||
@@ -15,7 +15,7 @@
|
|||||||
<a href="{{ urls.JoinPath .Site.BaseURL "contact" }}">Contact</a>
|
<a href="{{ urls.JoinPath .Site.BaseURL "contact" }}">Contact</a>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<img src="{{ $faceImage.Permalink }}" alt="Hazem Krimi's face">
|
<img src="{{ $faceImage.Permalink }}" alt="Hazem Krimi's face" loading="lazy">
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
<section id="about">
|
<section id="about">
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{{ $cv := resources.Get "cv.pdf" }}
|
{{ $cv := resources.Get "cv.pdf" }}
|
||||||
{{ $faceImage := resources.Get "images/borded-face.png" }}
|
{{ $faceImage := resources.Get "images/borded-face.webp" }}
|
||||||
|
|
||||||
<div id="about-card">
|
<div id="about-card">
|
||||||
<img src="{{ $faceImage.Permalink }}" alt="Hazem Krimi's face" />
|
<img src="{{ $faceImage.Permalink }}" alt="Hazem Krimi's face" />
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{{ $faceImage := resources.Get "images/small-face.png" }}
|
{{ $faceImage := resources.Get "images/small-face.webp" }}
|
||||||
{{ $cv :=resources.Get "cv.pdf" }}
|
{{ $cv :=resources.Get "cv.pdf" }}
|
||||||
|
|
||||||
<footer>
|
<footer>
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{{ $faceImage := resources.Get "images/small-face.png" }}
|
{{ $faceImage := resources.Get "images/small-face.webp" }}
|
||||||
{{ $cv := resources.Get "cv.pdf" }}
|
{{ $cv := resources.Get "cv.pdf" }}
|
||||||
|
|
||||||
<header>
|
<header>
|
||||||
|
|||||||