Pythonic JavaScript

JavaScript with Python Syntax. No more curly braces!

For example:

var el = document.getElementById("string")
  for var i=0; i<5; i++: el.innerHTML += "hello! "
  
  var count = 0
  for var i=0; i<5; i++:
    count += 1
    if count==2:
      count *= 5
  
  document.getElementById("count").innerHTML = count;    
  
  function triangle(a,b):
    function sqroot(x): return Math.pow(x,.5)
    return sqroot( a*a + b*b )
  
  document.getElementById("triangle").innerHTML = triangle(3,4);

93 views and 0 responses