3 ms·
Is there a blog post out there on the reasoning behind choosing Python instead of JavaScript for that component model + API? Just seems odd to add a 4th languag
by heartbreak 9y ago
Is there a blog post out there on the reasoning behind choosing Python instead of JavaScript for that component model + API? Just seems odd to add a 4th language to the mix.
- true_religion 9y agoI'm just guessing but by using Python, they can go with a more robust module system, and there's a semantic break between Anvil's Language and its output. If they used Javascript, you might be confused because they'd process your Javascript into other Javascript before it's used on the site, and you can edit it. That's a bit confusing isn't it? Knowing to begin with that the input language is a whole separate thing, is less confusing.
- meredydd 9y agoSpot on! If we used JS, it would be very difficult to maintain the firm layer of abstraction that gets us out of the Turing Tarpit. Also, to a first approximation, people don't learn JS on its own. You only learn it if you're already learning traditional front-end development. That's a journey we explicitly want to save people from - so we didn't want to use a language that only web devs know. Python is a lot easier to pick up for non-Pythonistas than JS is for non-web developers. Perhaps we should write that blog post...