Remix.run Logo
atum47 3 days ago

On my first official job after college I was working on making a web version of a Delphi software. The team was already on their third rewrite of the front end cause they had to change frameworks. I made the cass that we should write our own framework, so I prototyped FOS (the components I use on my website) to prove my point. The team (a bunch of mostly Delphi programmers) did not like my suggestion. Anyways, soon after that another company made me a better offer so I left. Years went by an I finally take a shot at another framework: tiny.js [1]. I've been using it in all my personal projects so far. I'm particular proud of the ColorPicker [2] component I wrote that I've used in two projects so far. As you can see, one can argue that tiny.js it's not a framework at all, just some wrapper functions that helps you create Functional components.

1 - https://github.com/victorqribeiro/TinyJS

2 - https://github.com/victorqribeiro/Chip8js/blob/master/js/Col...

npodbielski 3 days ago | parent | next [-]

I dont know... I kind of like diffrent look of HTML and JS. At least you know what is what. In tiny evrything looks like JS and you actually have to read it to know what is what. Also what if someone will define span variable? Does it override the span HTML component function?

Otherwise looks like nice.

atum47 3 days ago | parent [-]

    In tiny evrything looks like JS and you actually have to read it to know what is what
You don't, actually. If in HTML you write <select><option/><select/> in tiny you write select(option())

    Also what if someone will define span variable? 
I'm guilty of that myself. Tried to name a variable input when there's already a function with that name. It forces me to come up with better descriptive names. I could've wrapped those functions inside namespace like tiny.input() but I like the simplicity of it as is.
hu3 3 days ago | parent | prev [-]

You might want to look at something like morph Dom to keep input focus when you have to re-render the form, for example.

atum47 3 days ago | parent [-]

Since the user decides what happens when the state gets updated its up to them to address that. For me, I usually avoid re-renders when possible, I rather update the property associated with the state.

Have you faced any scenarios where that's needed? I'm curious.