Chaining in Bosque
Alright, now it is time to introduce a fresh concept! In Bosque, there is a special none
value that is basically – as the name suggests – a value representing no value. It is pretty similar to the null
value from other languages, or – in some cases – to undefined
if you are familiar with JavaScript.
Every programmer who has faced the challenge of handling such no-value values knows how hard is it, especially when we need to perform chaining where one of the middle components may be none
(or null
). I'm pretty sure you already know what chaining is but in case you don't, it is worth reminding that chaining is the process of accessing values or calling methods that are nested deep inside each other. An example of such a nested structure can be seen in the following example:
let merchCategories = { accessories = { kitchen = { ...