Live data from Hacker News

Show HN: My new JavaScript MVC framework

lhorie.github.io

11–20 of 167 posts

Re: Show HN: My new JavaScript MVC framework

#12

Off-topic: how do you apply animation to your logo on activation of the browser tab? I loaded your page in a new tab, but the logo animation didn't fire until I viewed that specific tab.

The three rings are in a span. So it's content 'o' in span, the 'o' in :before and 'o' in :after.

Then he uses a -webkit-animation to translate the positions of each ring.

    @keyframes logo {
    	from {opacity:0;transform:scale(2) rotate(359deg);}
    	to {opacity:1;transform:scale(1) rotate(0deg);}
    }
    @-webkit-keyframes logo {
    	from {opacity:0;-webkit-transform:scale(2) rotate(359deg);}
    	to {opacity:1;-webkit-transform:scale(1) rotate(0deg);}
    }

Re: Show HN: My new JavaScript MVC framework

#16
Overall I like it, except for the templates.

It's perfectly possible to not have FOUC with traditional template languages like mustache, and I don't think having "turing completeness" in your templates is a good thing. Frameworks like Ember.js have also shown that you don't need to manually write bindings to handle when your models change.

That being said, I do see the advantage gained with the virtual DOM you generate from the templates. I'd be interested to see if it was possible to integrate other templating languages in via plugin.

Re: Show HN: My new JavaScript MVC framework

#17
post #15

I don't mean this in a bad way, but do we really need another Javascript framework? Wouldn't author's energy be more useful when contributing to one of the existing ones?

Normally I'd agree, but I think this has compelling enough reason to be on it's own. The lightweight nature means it's only real competition is Backbone, which is more of a library for making a framework than a framework itself. But Mithril seems to do more while still managing to have a much lighter footprint and feel more like "just JavaScript".

Re: Show HN: My new JavaScript MVC framework

#18
post #16

Overall I like it, except for the templates. It's perfectly possible to not have FOUC with traditional template languages like mustache, and I don't think having "turing completeness" in your templates is a good thing. Frameworks like Ember.js have also shown that you don't need to manually write bindings to handle when your models change. That being said, I do see the advantage gained with the virtual DOM you genera…

Entirely agreed, this is what I was about to say as well. Being able to use html templates for me makes apps much less confusing and much more organized. Moving your html into your javascript just doesn't seem right. If there was a way that it would accept a mustache/underscore/other precompiled template I'd be all about it. But constructing html out of javascript functions and objects just doesn't sit right with me.

Re: Show HN: My new JavaScript MVC framework

#20

Off-topic: how do you apply animation to your logo on activation of the browser tab? I loaded your page in a new tab, but the logo animation didn't fire until I viewed that specific tab.

The three rings are in a span. So it's content 'o' in span, the 'o' in :before and 'o' in :after. Then he uses a -webkit-animation to translate the positions of each ring. @keyframes logo { from {opacity:0;transform:scale(2) rotate(359deg);} to {opacity:1;transform:scale(1) rotate(0deg);} } @-webkit-keyframes logo { from {opacity:0;-webkit-transform:scale(2) rotate(359deg);} to {opacity:1;-webkit-transform:scale(1) r…

But does that explain how it's not triggered until you click the tab?
Post reply on HN