# New book: Hands-on Design Patterns and Best Practices with Julia

**URL:** <https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712>\
**Category:** Community\
**Tags:** design-pattern\
**Created:** [January 23, 2020, 8:01pm UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712 "2020-01-23T20:01:36Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![tk3369](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tk3369/32/2824_2.png) [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Post date:** [January 23, 2020, 8:01pm UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/1 "2020-01-23T20:01:36Z")

</div>

Hi, everyone! 👋

I’m pleased announce that my first book [Hands-on Design Patterns and Best Practices with Julia](https://www.amazon.com/gp/product/183864881X) has been published. I want to thank everyone who helped me on Discourse / Slack before (too many to mention here). I also want to thank @StefanKarpinski for writing the forewords of this book.

# Why another book?

I spent a ton of time in the past 9 months researching and writing about patterns used by other Julia experts. Not only was it a great learning experience, it is also something that I believe this community needs based upon various discussions here e.g.

- [Design Pattern the Julian way?](https://discourse.julialang.org/t/design-pattern-the-julian-way/29002)
- [Composition and inheritance: the Julian way](https://discourse.julialang.org/t/composition-and-inheritance-the-julian-way/11231)
- [Tutorial on using advanced type system in Julia?](https://discourse.julialang.org/t/tutorial-on-using-advanced-type-system-in-julia/32903)
- etc etc etc.

I cannot say that this book has captured all the wisdom in this community, as that would have been an impossible task for such a short time frame. However, I strongly believe that it is a good time to start documenting design patterns for Julia a little more formally.

# Something for you…

1. I have published an excerpt about the [Holy Traits pattern](https://ahsmart.com/pub/holy-traits-design-patterns-and-best-practice-book.html) on my web site for your reading pleasure.

2. I’m waiting for the publisher to set up a discount code. I hope that will be ready within the next few days and I’ll post an update here.

Happy reading! 🙂

Tom

---

<div class="post-metadata">

**Author:** ![braamvandyk](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/braamvandyk/32/5086_2.png) [@braamvandyk](https://discourse.julialang.org/u/braamvandyk)\
**Post date:** [January 25, 2020, 7:52pm UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/2 "2020-01-25T19:52:55Z")

</div>

I just bought my copy. Nice! Thanks for putting this together.

---

<div class="post-metadata">

**Author:** ![PetrKryslUCSD](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/petrkryslucsd/32/215825_2.png) [@PetrKryslUCSD](https://discourse.julialang.org/u/PetrKryslUCSD)\
**Post date:** [January 26, 2020, 1:30am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/3 "2020-01-26T01:30:30Z")

</div>

Dear Tom,

Congratulations on the publication!

It is a pity the book wasn’t published in HTML. The Kindle version is not typeset well: messed up font sizes, weird sizing of images. On the other hand the sample chapter you published on the web is a real treat to read.

This is not intended to detract from the quality of the content, which I found to be high and an enjoyable read.

Best regards,

Petr

---

<div class="post-metadata">

**Author:** ![Alec\_Loudenback](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/alec_loudenback/32/278_2.png) [@Alec\_Loudenback](https://discourse.julialang.org/u/Alec_Loudenback)\
**Post date:** [January 26, 2020, 2:10am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/4 "2020-01-26T02:10:11Z")

</div>

I bought from Packt today, as they had digital, DRM-free versions available:

> **[Search | Packt Subscription](https://subscription.packtpub.com/search?query=hands%20design%20patterns%20julia%2010)**
>
> Search over 7,500 Programming & Development eBooks and videos to advance your IT skills, including Web Development, Application Development and Networking

---

<div class="post-metadata">

**Author:** ![Ralph\_Smith](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ralph_smith/32/10344_2.png) [@Ralph\_Smith](https://discourse.julialang.org/u/Ralph_Smith)\
**Post date:** [January 26, 2020, 4:29am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/5 "2020-01-26T04:29:06Z")

</div>

The quality of a Kindle ebook seems to be `~ Uniform(0,1)`.

On the other hand, the ebooks direct from Packt are of pretty high quality (in my experience). And – I hope, for Tom’s sake – the US $5 price is likely a promotional offer, so …

---

<div class="post-metadata">

**Author:** ![PetrKryslUCSD](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/petrkryslucsd/32/215825_2.png) [@PetrKryslUCSD](https://discourse.julialang.org/u/PetrKryslUCSD)\
**Post date:** [January 26, 2020, 4:34am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/6 "2020-01-26T04:34:27Z")

</div>

At one point I was looking at publishing a math-y textbook on Kindle. When it got formatted it looked like something no one in their right mind would buy. ☹

I certainly bought the Packt book: at $5 it is a great deal. 82% off.

---

<div class="post-metadata">

**Author:** ![tk3369](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tk3369/32/2824_2.png) [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Post date:** [January 26, 2020, 4:38am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/7 "2020-01-26T04:38:34Z")

</div>

Thanks, this is great feedback! I will check with the publisher 🙂

---

<div class="post-metadata">

**Author:** ![tk3369](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tk3369/32/2824_2.png) [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Post date:** [January 26, 2020, 4:47am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/8 "2020-01-26T04:47:29Z")

</div>

Interesting! I thought the $5 deal is a subscription. Perhaps they’re running a special at the moment. To be honest, I don’t expect to make much money from this anyways. I would be happy enough to reach more audience and see people benefit from it.

---

<div class="post-metadata">

**Author:** ![tk3369](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tk3369/32/2824_2.png) [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Post date:** [January 26, 2020, 5:12am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/9 "2020-01-26T05:12:16Z")

</div>

> [@PetrKryslUCSD](#):
>
> On the other hand the sample chapter you published on the web is a real treat to read.

BTW, my site is built with Franklin.jl. It’s very easy to use and I love it.

> **[GitHub - tlienart/Franklin.jl: (yet another) static site generator. Simple,...](https://github.com/tlienart/Franklin.jl)**
>
> (yet another) static site generator. Simple, customisable, fast, maths with KaTeX, code evaluation, optional pre-rendering, in Julia.

---

<div class="post-metadata">

**Author:** ![mauro3](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mauro3/32/292_2.png) [@mauro3](https://discourse.julialang.org/u/mauro3)\
**Post date:** [January 26, 2020, 7:11am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/10 "2020-01-26T07:11:27Z")

</div>

> [@tk3369](#):
>
> Interesting! I thought the $5 deal is a subscription. Perhaps they’re running a special at the moment.

Looks like all ebooks are currently $5.

---

<div class="post-metadata">

**Author:** ![tomtom](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tomtom/32/5106_2.png) [@tomtom](https://discourse.julialang.org/u/tomtom)\
**Post date:** [February 3, 2020, 3:24pm UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/11 "2020-02-03T15:24:09Z")

</div>

many thanks for the book!

---

<div class="post-metadata">

**Author:** ![IljaK91](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/iljak91/32/44301_2.png) [@IljaK91](https://discourse.julialang.org/u/IljaK91)\
**Post date:** [February 3, 2020, 4:40pm UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/12 "2020-02-03T16:40:32Z")

</div>

Thanks, I’ll give it a read 🙂

---

<div class="post-metadata">

**Author:** ![tomtom](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tomtom/32/5106_2.png) [@tomtom](https://discourse.julialang.org/u/tomtom)\
**Post date:** [February 4, 2020, 8:07am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/13 "2020-02-04T08:07:02Z")

</div>

hello, how could I report typos?

---

<div class="post-metadata">

**Author:** ![tk3369](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tk3369/32/2824_2.png) [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Post date:** [February 4, 2020, 8:27am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/14 "2020-02-04T08:27:46Z")

</div>

Direct Message, Slack, or email would be fine. It’s easy to fix if the typo is in the blog post. It’s probably going to take a while to correct the book itself as it involves working with the publisher.

Many thanks.

---

<div class="post-metadata">

**Author:** ![oheil](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/oheil/32/220745_2.png) [@oheil](https://discourse.julialang.org/u/oheil)\
**Post date:** [February 4, 2020, 8:55am UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/15 "2020-02-04T08:55:18Z")

</div>

> [@tk3369](#):
>
> I have published an excerpt about the [Holy Traits pattern](https://ahsmart.com/pub/holy-traits-design-patterns-and-best-practice-book.html) on my web site for your reading pleasure.

Read it … had some pleasure … found it well comprehendable … bought the eBook (currently on discount at Packt!)

😄

---

<div class="post-metadata">

**Author:** ![mthelm85](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mthelm85/32/224164_2.png) [@mthelm85](https://discourse.julialang.org/u/mthelm85)\
**Post date:** [February 4, 2020, 1:54pm UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/16 "2020-02-04T13:54:35Z")

</div>

@tk3369 I’m not quite 100 pages into the e-book yet and I can already see that I need to rethink some of my code 🙂 This is good stuff, thank you.

EDIT: I’m about halfway through and this is a really great book. JavaScript was my first programming language and Kyle Simpson’s book _You Don’t Know JS_ was a real eye-opener and took my understanding of that language to a whole new level. I would almost argue that the title of this book is a bit misleading because it really provides the reader with an in-depth understanding of how Julia works, just like the Simpson book on JavaScript. Julia docs are generally really good but working through this book has really accelerated the process of gaining a deeper understanding of Julia!

---

<div class="post-metadata">

**Author:** ![tk3369](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tk3369/32/2824_2.png) [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Post date:** [February 12, 2020, 3:13pm UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/17 "2020-02-12T15:13:18Z")

</div>

> [@tk3369](#):
>
> I’m waiting for the publisher to set up a discount code. I hope that will be ready within the next few days and I’ll post an update here.

Hi everyone - the publisher has agreed to a **20% discount** for **30 people**. Here’s the procedure if you want to take advantage of this:

1. **You** : send me a private message with your email address
2. **Me** : collect up to 30 email addresses and send to the publisher for a discount code
3. **Me** : reply to you with the 20%-off discount code
4. **You** : make your purchase within 30 days

Please take action earlier if you wish to buy. The earlier that I can fill up the list, the earlier that everyone will receive the book.

Tom

---

<div class="post-metadata">

**Author:** ![tk3369](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tk3369/32/2824_2.png) [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Post date:** [February 28, 2020, 9:31pm UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/18 "2020-02-28T21:31:28Z")

</div>

Hi all, just a quick update:

The publisher has set up a 20% discount code if you buy the book from [Amazon.com](http://Amazon.com). The code is **20JULIA**. Please note that the code will expire by March 22.

Here’s a direct link [Amazon.com Page Not Found](https://www.amazon.com/gp/mpc/A1CVEJLTXCXY1Y)

Tom

---

<div class="post-metadata">

**Author:** ![Pere](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/pere/32/214250_2.png) [@Pere](https://discourse.julialang.org/u/Pere)\
**Post date:** [March 6, 2020, 2:21pm UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/19 "2020-03-06T14:21:17Z")

</div>

I’ve signed up for the Packt trial to check out the book and I’m liking it so far. I prefer the version on the Packt site versus the pdf ebook (saw a preview on Google books), do you know if it’ll be accessible without a subscription once I buy the ebok?

---

<div class="post-metadata">

**Author:** ![tk3369](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/tk3369/32/2824_2.png) [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Post date:** [March 6, 2020, 2:39pm UTC](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712/20 "2020-03-06T14:39:40Z")

</div>

Let me find out and get back to you. In what aspect do you like the Packt subscription version better? Isn’t it the same content?

[Next page](https://discourse.julialang.org/t/new-book-hands-on-design-patterns-and-best-practices-with-julia/33712.md?page=2)
