Question, why a strong emphasis on Strings? #276
Replies: 2 comments
-
Hi, Good question. Short answer: I wouldn't do it again 😂 Long answer: First of all, because when I started this library I planned to use it for live coding music, so I wanted to represent things in the most human way possible. Also at that time I was new to functional programming and types, so how data structures fits in a functional model or how to make functions easy to combine was not very clear to me. Of course, I'm open to suggestions for improvement (but I'd like to keep things compatible -as much as possible- and easy to start with for novice programmers) |
Beta Was this translation helpful? Give feedback.
-
That makes sense! Thanks for explaining! |
Beta Was this translation helpful? Give feedback.
-
Hi,
I love the tonaljs library! I don't really have an issue to report, but just a question: why do so many functions return arrays of strings instead of typed values? If you want to make combinations of function calls, it would be much easier to work directly with the
Note
objects rather than the String names of of notes as a result of aScale.get
function for instance.Just curious about the reason behind this design decision...
Thanks!
Beta Was this translation helpful? Give feedback.
All reactions