Skip to content

Commit

Permalink
Minor content updates
Browse files Browse the repository at this point in the history
  • Loading branch information
lmammino committed Jan 1, 2024
1 parent 704fd93 commit 52bebbe
Show file tree
Hide file tree
Showing 6 changed files with 94 additions and 76 deletions.
2 changes: 1 addition & 1 deletion _11ty/minifyhtml.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ const banner = `<!--
> Hey, it seems you are a curious one and that you like to hack! :)
> Maybe you should follow us on Twitter at @mariocasciaro & @loige
> Maybe you should follow us on X at @mariocasciaro & @loige
> Did you know that this website is open source?
> Check out https://github.com/nodejs-design-patterns-book/nodejsdesignpatterns.com
Expand Down
4 changes: 4 additions & 0 deletions _11ty/shareImage.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ export default function shareImage (config) {
throw new Error('Missing `title` on generateShareImage')
}

if (typeof this.page.fileSlug === 'undefined') {
return 'https://www.nodejsdesignpatterns.com/img/node-js-design-patterns.jpg'
}

const filename = `og_${this.page.fileSlug}.jpg`
const destFolder = dirname(this.page.outputPath)
await mkdirp(destFolder)
Expand Down
2 changes: 1 addition & 1 deletion src/_data/faqs.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ into practice. Node.js Design Patterns contains 50 exercises in total.`
{
id: 'faq-more-questions',
question: 'I have more questions!',
answer: `You are more than welcome to reach out to the authors on Twitter
answer: `You are more than welcome to reach out to the authors on X
([@mariocasciaro](https://twitter.com/mariocasciaro) and [@loige](https://twitter.com/loige)) or you can write an email to
[authors@nodejsdesignpatterns.com](mailto:authors@nodejsdesignpatterns.com).`
}
Expand Down
14 changes: 7 additions & 7 deletions src/_includes/article.njk
Original file line number Diff line number Diff line change
Expand Up @@ -68,13 +68,13 @@ eleventyComputed:

<h3 class="title is-4">Share</h3>

<a title="Share this article on Twitter" class="share-btn twitter" href="https://twitter.com/share?url={{ (site.url + page.url) | urlencode}}&text={{ title | urlencode }}&hashtags=nodejs" target="_blank">
<svg xmlns="http://www.w3.org/2000/svg"
aria-label="Twitter" role="img"
viewBox="0 0 512 512"
width="32px" height="32px">
<rect width="512" height="512" rx="15%" fill="#1da1f2"/>
<path fill="#fff" d="M437 152a72 72 0 0 1-40 12 72 72 0 0 0 32-40 72 72 0 0 1-45 17 72 72 0 0 0-122 65 200 200 0 0 1-145-74 72 72 0 0 0 22 94 72 72 0 0 1-32-7 72 72 0 0 0 56 69 72 72 0 0 1-32 1 72 72 0 0 0 67 50 200 200 0 0 1-105 29 200 200 0 0 0 309-179 200 200 0 0 0 35-37"/>
<a title="Share this article on X" class="share-btn twitter" href="https://twitter.com/share?url={{ (site.url + page.url) | urlencode}}&text={{ title | urlencode }}&hashtags=nodejs" target="_blank">
<svg width="32px" height="32px" viewBox="0 0 32 32" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:2;">
<path d="M27.2,32L4.8,32C2.151,32 0,29.849 0,27.2L0,4.8C0,2.151 2.151,0 4.8,0L27.2,0C29.849,0 32,2.151 32,4.8L32,15.815C32.001,15.95 32.001,16.086 32,16.221L32,27.2C32,29.849 29.849,32 27.2,32ZM14.495,10.027L12.012,6.711L9.082,6.711C7.466,6.711 6.15,6.722 6.15,6.743C6.15,6.764 7.862,9.065 9.948,11.846C12.034,14.638 13.735,16.959 13.724,17.003C13.703,17.034 11.992,18.906 9.926,21.142C7.851,23.378 6.15,25.24 6.15,25.272C6.15,25.303 6.525,25.325 6.984,25.325L7.808,25.325L11.071,21.784C12.868,19.838 14.388,18.2 14.452,18.147C14.537,18.082 15.415,19.163 17.287,21.677L20.004,25.314L22.924,25.325C24.519,25.325 25.834,25.293 25.834,25.24C25.834,25.196 24.026,22.758 21.823,19.816L17.811,14.478L18.324,13.932C18.613,13.643 20.068,12.071 21.555,10.455C23.042,8.84 24.433,7.331 24.647,7.107L25.021,6.711L23.277,6.711L20.207,10.027C18.528,11.846 17.105,13.344 17.062,13.344C17.019,13.344 15.863,11.846 14.495,10.027Z"/>
<path d="M14.495,10.027C15.863,11.846 17.019,13.344 17.062,13.344C17.105,13.344 18.528,11.846 20.207,10.027L23.277,6.711L25.021,6.711L24.647,7.107C24.433,7.331 23.042,8.84 21.555,10.455C20.068,12.071 18.613,13.643 18.324,13.932L17.811,14.478L21.823,19.816C24.026,22.758 25.834,25.196 25.834,25.24C25.834,25.293 24.519,25.325 22.924,25.325L20.004,25.314L17.287,21.677C15.415,19.163 14.537,18.082 14.452,18.147C14.388,18.2 12.868,19.838 11.071,21.784L7.808,25.325L6.984,25.325C6.525,25.325 6.15,25.303 6.15,25.272C6.15,25.24 7.851,23.378 9.926,21.142C11.992,18.906 13.703,17.034 13.724,17.003C13.735,16.959 12.034,14.638 9.948,11.846C7.862,9.065 6.15,6.764 6.15,6.743C6.15,6.722 7.466,6.711 9.082,6.711L12.012,6.711L14.495,10.027ZM8.793,8.145C8.836,8.219 11.531,11.835 14.762,16.157L20.646,24.03L21.961,24.041C22.774,24.041 23.267,23.999 23.245,23.934C23.235,23.881 20.55,20.265 17.298,15.911L11.37,7.995L10.044,7.995C8.943,7.995 8.718,8.017 8.793,8.145Z" style="fill:white;"/>
<g transform="matrix(0.213955,0,0,0.213955,-0.0543541,-0.0285703)">
<path d="M41.353,38.2C41.551,38.55 54.148,55.45 69.25,75.648L96.75,112.449L102.898,112.5C106.699,112.5 109,112.3 108.898,112C108.852,111.75 96.301,94.852 81.102,74.5L53.398,37.5L47.2,37.5C42.052,37.5 41.001,37.602 41.353,38.2Z"/>
</g>
</svg>
</a>

Expand Down
13 changes: 4 additions & 9 deletions src/index.html.njk
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,6 @@ og_type:
</div>
</div>
<div class="column pos-rel">
<div class="floating-label">
<a href="#buy">
<span class="tag is-primary">
<strong>New Edition!</strong></span></a>
</div>
{% responsiveImage './img/book-stack.png', 'Node.js Design Patterns book cover', { class: 'book-cover', maxWidth: 580 } %}
</div>
</div>
Expand Down Expand Up @@ -303,13 +298,13 @@ og_type:
{% responsiveImage './img/mario-casciaro.jpg', "Mario Casciaro's picture", {class: 'avatar', maxWidth: 300} %}
</div>
<div class="column is-two-third">
<p>Mario is a software engineer and entrepreneur who worked at IBM for a number of years. He currently splits his time between Var7 Technologies (his own software company) and its role as Lead Engineer at D4H Technologies where he creates software for emergency response teams.</p>
<p>Mario is a software engineer and entrepreneur who worked at IBM for a number of years. He currently splits his time between Var7 Technologies (his own software company) and its role as CTO at D4H Technologies where he creates software for emergency response teams.</p>
<ul>
<li>
<a title="Visit Mario's blog" target="_blank" rel="me noopener" href="https://mario.fyi/">Blog</a>
</li>
<li>
<a title="Visit Mario's Twitter profile" target="_blank" rel="me noopener noreferrer" href="https://twitter.com/mariocasciaro">Twitter</a>
<a title="Visit Mario's X profile" target="_blank" rel="me noopener noreferrer" href="https://twitter.com/mariocasciaro">X</a>
</li>
<li>
<a title="Visit Mario's GitHub profile" target="_blank" rel="me noopener noreferrer" href="https://github.com/mariocasciaro">GitHub</a>
Expand All @@ -334,13 +329,13 @@ og_type:
{% responsiveImage './img/luciano-mammino.jpg', "Luciano Mammino's picture", {class: 'avatar', maxWidth: 300} %}
</div>
<div class="column is-two-third">
<p>Luciano wrote his first line of code at the age of 12 on his father's old i386. Since then, he has never stopped coding. He is working at FabFitFun as Principal Software Engineer where he is building software to serve millions of users every day. He is an active speaker and in the last few years he has delivered more than 50 talks.</p>
<p>Luciano wrote his first line of code at the age of 12 on his father's old i386. Since then, he has never stopped coding. He is working at fourTheorem as a Senior Architect where he is helping companies to get the best out of the Cloud and AWS. He is an active speaker and in the last few years he has delivered more than 130 talks.</p>
<ul>
<li>
<a title="Visit Luciano's blog" target="_blank" rel="me noopener" href="https://loige.co/">Blog</a>
</li>
<li>
<a title="Visit Luciano's Twitter profile" target="_blank" rel="me noopener noreferrer" href="https://twitter.com/loige">Twitter</a>
<a title="Visit Luciano's X profile" target="_blank" rel="me noopener noreferrer" href="https://twitter.com/loige">X</a>
</li>
<li>
<a title="Visit Luciano's GitHub profile" target="_blank" rel="me noopener noreferrer" href="https://github.com/lmammino">GitHub</a>
Expand Down
Loading

0 comments on commit 52bebbe

Please sign in to comment.