News for hackers. Stuff that matters.
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by gtsteve on Tuesday January 07, 2020 @04:16AM (#21978323)
Nice, this reminds me of the Jade templating language [0], although after a bit of Googling I see it's now called Pug [1].

[0] http://jade-lang.com/

[1] https://github.com/pugjs/pug

Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by SzamarCsacsi on Tuesday January 07, 2020 @05:28AM (#21978676)
Pug is actually awesome. I use it daily with Vue and I just introduced it to a project I was put on recently.
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by Robin_Message on Tuesday January 07, 2020 @03:16AM (#21978058)
The comma and dot seem weird; curly braces would feel more natural to me. In your example, style isn't terminated by a dot, but other one liners are, which I'm assuming is just a typo else I'm really confused.

What's the advantage over JSX?

Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by m0zg on Tuesday January 07, 2020 @06:46AM (#21979073)
Any relation to the pronunciation video: https://www.youtube.com/watch?v=Pa1vXovXn-M ?

:-)

Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by wwwigham on Tuesday January 07, 2020 @04:14AM (#21978316)
I love me a good, simple, jokey template language. Reminds me of the one I made a few years back[1]. Everyone should write a small template language of their own - it's a neat parser-writing exercise, and the rendering implementation can be comparatively trivial (assuming you don't plan to actually use it in a place where rendering perf matters).

[1] http://ham.io/not.js/

Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by everdev on Monday January 06, 2020 @11:51PM (#21976965)
Interesting project, but why are there Pepsi and PlayStation logo images in the Readme?
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by saagarjha on Monday January 06, 2020 @11:55PM (#21976991)
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by stallmanite on Monday January 06, 2020 @11:54PM (#21976983)
To my understanding “bepis” is a goofy vaporwave/meme/shitpost-y concept loosely based on Pepsi.
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by slightlyCyborg on Wednesday January 08, 2020 @08:39AM (#21991286)
This is awesome. Reminds me of Clojure's https://github.com/weavejester/hiccup which blows every template engine I've ever used out of the water.
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by limelights on Tuesday January 07, 2020 @12:48AM (#21977288)
Cool project! It reminds me of http://haml.info
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by z3t4 on Tuesday January 07, 2020 @02:13AM (#21977738)
Using document.createElement to create elements and element.appendChild(node) to add them is tedious. But once you have abstractions in place, like var menu = createMenu(), subMenu=createMenu(), menu.add(subMenu) it becomes very powerful and more fun to work with the DOM.
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by NohatCoder on Tuesday January 07, 2020 @02:58AM (#21977975)
Time to shill my own alternative.

https://github.com/NoHatCoder/DOM_Maker

No parser, just a bunch of JavaScript functions that nest nicely, to create dense and readable DOM generation code.

Might be time for putting a 1.0 sticker on it.

As for Bepis, the mechanism by which elements nest seem complicated, as far as I understand it is controlled by sprinkling , and . throughout the string, I don't get why this would be necessary.

Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by undecisive on Tuesday January 07, 2020 @04:45AM (#21978445)
As someone else mentioned, everyone should do this. I've got a similar coffeescript one:

https://github.com/undecided/tg

(totally usable in vanilla JS too)

Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by scotty79 on Tuesday January 07, 2020 @04:34AM (#21978396)
Why no examples in the readme?
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by kinlan on Tuesday January 07, 2020 @04:36AM (#21978407)
snap!
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by NohatCoder on Tuesday January 07, 2020 @01:14PM (#21982750)
I guess I am better at writing libraries than marketing. So that is definitely on the todo list now.
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by kinlan on Tuesday January 07, 2020 @04:36AM (#21978406)
It would be great for people just visiting DOM_Maker to be able to quickly see an example in the README file of the syntax etc.
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by nwsm on Tuesday January 07, 2020 @08:52AM (#21979858)
Lol I was hoping that's what the name would be referencing.
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by zipster90 on Tuesday January 07, 2020 @05:28PM (#21985807)
Refreshing!
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by sergiotapia on Tuesday January 07, 2020 @01:37AM (#21977550)
looks like haml
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by imvetri on Tuesday January 07, 2020 @08:51AM (#21979847)
Pepsi? why that company!
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by rhabarba on Tuesday January 07, 2020 @06:50AM (#21979090)
Parenscript, but worse.
Re:Show HN: Bepis – Crazy Format for HTML+CSS in JavaScript by crtlaltdel on Monday January 06, 2020 @11:45PM (#21976940)
this is pretty neat!