This one is 25 bytes gzipped http://vanilla-js.com/
Show HN: HyperApp – 1k JavaScript framework for building web applications
31–40 of 169 posts
Re: Show HN: HyperApp – 1k JavaScript framework for building web applications
#32Re: Show HN: HyperApp – 1k JavaScript framework for building web applications
#33Side question: Isn't it grossly inefficient that in Redux, you have reducers that return an entirely new state object? Wouldn't it be better to return some kind of data that represents just the diff you intend to make, like {op: INCREMENT, arg: 1, key: "Foo"}?
Re: Show HN: HyperApp – 1k JavaScript framework for building web applications
#34Side question: Isn't it grossly inefficient that in Redux, you have reducers that return an entirely new state object? Wouldn't it be better to return some kind of data that represents just the diff you intend to make, like {op: INCREMENT, arg: 1, key: "Foo"}?
Re: Show HN: HyperApp – 1k JavaScript framework for building web applications
#35Where JSX would look like this:
const view = (state, actions) => (
{state.count}
actions.down(1)}>-
actions.up(1)}>+
)
The lit-html would be: const view = (state, actions) => html`
{state.count}
actions.down(1)}>-
actions.up(1)}>+
`;
Nearly identical. lit-html uses ``s and cloning, so that it doesn't have to do any expensive VDOM diffs.Re: Show HN: HyperApp – 1k JavaScript framework for building web applications
#36If you're interesting in a reactive template library that doesn't require a compiler for non-standard JavaScript syntax, check out a library I've been working on for a little while now, lit-html: https://github.com/Polymer/lit-html Where JSX would look like this: const view = (state, actions) => ( {state.count} actions.down(1)}>- actions.up(1)}>+ ) The lit-html would be: const view = (state, actions) => html` {state.…
Re: Show HN: HyperApp – 1k JavaScript framework for building web applications
#37Re: Show HN: HyperApp – 1k JavaScript framework for building web applications
#38If you're interesting in a reactive template library that doesn't require a compiler for non-standard JavaScript syntax, check out a library I've been working on for a little while now, lit-html: https://github.com/Polymer/lit-html Where JSX would look like this: const view = (state, actions) => ( {state.count} actions.down(1)}>- actions.up(1)}>+ ) The lit-html would be: const view = (state, actions) => html` {state.…
Then you need to send lit-html over to the client also. This would be a great alternative if one doesn't already use Babel, but what's the selling point otherwise? Is there an easy way to combine lit-html's render with the HyperApp one?
Web Components and Shadow DOM make this possible. You can mix and match components that use lit-html, Polymer, Preact, etc., and mostly likely HyperApp.
Re: Show HN: HyperApp – 1k JavaScript framework for building web applications
#39If you're interesting in a reactive template library that doesn't require a compiler for non-standard JavaScript syntax, check out a library I've been working on for a little while now, lit-html: https://github.com/Polymer/lit-html Where JSX would look like this: const view = (state, actions) => ( {state.count} actions.down(1)}>- actions.up(1)}>+ ) The lit-html would be: const view = (state, actions) => html` {state.…
Re: Show HN: HyperApp – 1k JavaScript framework for building web applications
#40Wow, there's an overwhelming total of 2 comments in the source file. The first indicates a constant value. The second lacks all context. Looks like typical JavaScript code.
Maybe there's simply nothing else to say.