News for hackers. Stuff that matters.
Re:Flat HTML by torgoguys on Wednesday April 01, 2020 @10:21AM (#22748743)
What has the world come to if this mess is considered easier than writing some nested html tags? (Perhaps I'm not plugged into the SPA scene well enough to appreciate this project. I hope it is useful to some.) In fact, reading the examples made me check to see if the first commit to this project was today, April Fools...
Re:Flat HTML by bscphil on Wednesday April 01, 2020 @11:42PM (#22756015)
The link was shared here by someone with the same username as the github repo owner - presumably it was a pre-planned April Fools day joke for Hacker News.
Re:Flat HTML by mdturnerphys on Thursday April 02, 2020 @03:08AM (#22756879)
It looks like the owner has shared it three times in the last 2 weeks, which suggests it isn't a joke.
Re:Flat HTML by m463 on Thursday April 02, 2020 @12:12AM (#22756122)
Come on, this is cutting edge stuff.

Personally I've been considering an alternative representation of python using YAML.

for example this python:

  if a == 3:
    b = y * 3
  else:
    b = x + 4
could be represented in YAML python as:

  if a == 3:
    b = y * 3
  else:
    b = x + 4
Re:Flat HTML by Stratoscope on Thursday April 02, 2020 @12:33AM (#22756224)
That is amazing!

I hope you can share the toolchain that lets you convert from one to the other so seamlessly?

Re:Flat HTML by m463 on Thursday April 02, 2020 @12:43AM (#22756266)

     I will as soon as the indentation technology has been worked out, and the API stabilized and a documentation framework has been completed, targeting 4/1/21.
Re:Flat HTML by laumars on Thursday April 02, 2020 @02:34AM (#22756745)
4th of Jan?

;)

Re:Flat HTML by panic on Thursday April 02, 2020 @02:51AM (#22756801)
One advantage is security. The text after the equals sign in each string can't be misinterpreted as HTML syntax, so it's safe to build flat HTML using string concatenation.
Re:Flat HTML by ludami on Wednesday April 01, 2020 @11:06AM (#22749395)
I really hope it's a joke. I mean it's not even flat. It's just the nesting is represented in a different less intuitive way.
Re:Flat HTML by mebr on Wednesday April 01, 2020 @11:13PM (#22755920)
The reason behind the design is not mentioned. Why would one take this seriously?
Re:Flat HTML by zuckluni on Thursday April 02, 2020 @01:58AM (#22756584)
Replugging bepis, another way to write 'flat' HTML using operators with a slightly different operator set: https://github.com/dosyago/bepis

For me I just wanted to stop writing all the extra syntax (like `< > =` and closing tags) and use symbols my fingers were already reaching for. Just about conciseness, efficiency and enjoyment.

I really like the operator choice in this project!