208 karma · joined August 3, 2020
No idea how the processors compare, but that RAM isn't a good sign
Mind blowing that there might be a solar system out there with a collection of orbiting objects whose final object could have square orbit
Naming still remains the hardest programming problem ...
Would be a much better use of their time than writing this nonsensical bs
Then rather than marking a function as pure you instead check it is pure by looking at what effects its function type has!
On the other hand Ezno a semi compatible TypeScript compiler can use a more low level binary format which is only one pass and whose name references are already resolved https://twitter.com/kaleidawave/status/1596445852918325250?s... . This is only really possible because it is written in Rust so low level byte and memory management is relatively simple
Eagerly downloading JS is something every framework does though and many only download for the current view through code splitting for the current page. It doesn't fix the later two problems..., struggling to find any benefits above existing techniques here :/
Instead if you like stricter types, `.map`, and `.push` JSX and want to reduce the runtime abstraction by moving it to compile time then it offers a possible alternative to React. Haven't gone into too much yet but there is a probably a lot of React applications that are too complicated for the optimiser to work :( and there it won't be an alternative.
Lots of great alternatives to React these days as well which I also want to promote!
The automatic / inferred generic restrictions is quite cool. https://hegel.js.org/ got there before me! Basic restriction modification is quite simple e.g. `(x) => Math.sin(x)`, x wants to be a number so can add that restriction. It gets more difficult with higher poly types. `(someObj) => Math.sin(someObj.prop1.prop2)` requires modifying not just `someObj` but a property on a property on it. And `(x, y) => printString(x + y)` requires doing even more complex things. But its definitely possible!
In short not only is a collision bad but it could create a chain reaction leading to billions of small objects flying around in the orbit forming a impenetrable barrier that bars further space travel and more importantly putting other (actually useful) satellites at risk
document.querySelector("input").addEventListener("input", e => { document.querySelector("p").innerHTML = `<strong>${e.target.value}</strong>` });
Reusing the logic could be done if the server was node or through compiling the formatter to wasm. I struggle to see how Hotwire makes things simpler and has comparable speed to a SPA?Little confused how it works out the page though. Looking at the given snippet it doesn't seem to include anything and the pathname I am hitting is showing up on the dashboard as "/". Maybe missing sending "window.location.pathname"? And a super tiny thing but "navigator.sendBeacon" maybe better over "fetch". Other that super work!
And as understand all these tools use a lexing and ast parsing stage. It would be interesting if you could build a very simple minifier (at least a whitespace one) that could skip that step through just working on input buffer?
There is also the fact that more code means longer minification time. You can praise esbuild for building a CRA in 2 seconds but there are workflows/frameworks that compile sub second by using less runtime code.
No Intl support and no http2 have been a drain this year but those seem to be coming soon as they are on the Q1 2021 roadmap.
The import/module system is great. Can all tooling convening on including extensions in imports (looking at you TypeScript)
The article also skims over the single ownership model which is a big difference with Rust. And it does miss about creating macros, cells, threading & mutexes, heap allocated types, unsafe code, Rc, std::mem, and the whole crates and cargo ecosystem. Which is why I think this should have been titled "half-hour introduction to Rust syntax". Hopefully this does bring more people on the Rust train. I think 2021 will be a good year for Rust :)
Just looked and Turbo is 135kb. I rewrote this website (http://40.115.126.159/) with my own JS framework and it comes at 15kb, that's 9x smaller Turbo...
Seems odd that they haven't worked out how this works for routing yet (https://github.com/reactjs/rfcs/blob/07dd4bc4807605020351606...) and that in the demo the whole app is rendered, not individual components. Just seems like turbolinks but for rendering to React VDOM rather than HTML. And I thought most people used React for CSR through hosting files on static buckets leaving out the server...?
This also uses my own frontend web framework Prism. Prism is a new web framework which has the ability to "prerender" pages in Rust. Kinda of like something like NextJS is but the render functions are native/pure rust code. There is no other frontend web framework (React, Vue, Svelte) which has this ability, Prism is the first.
Maybe you are writing are site which does rendering through a server side templating language. These are purely server side rendering solutions and miss out on some of the progressive benefits of client side rendering, routing and runtime JS. Using Prism you can get those benefits but can build backend and server side rendering in Rust rather than have to shell out a slower JS server.
It also has a special technique for hydration that is much faster than partial hydration as does not require any JS state blob or rerender on load. You can read about this here: https://dev.to/kaleidawave/jit-hydration-4b62
I have a full article more about the development here: https://kaleidawave.medium.com/hacker-news-clone-with-prism-...
And the site is public here: http://40.115.126.159/
This is very experimental at this stage , if you are writing sites that do SSR in a language other than JS, Prism is working on enable compilation for other languages such has been done for Rust. It would be great to hear your opinions on it!
lol wtf "dehydration" haha (also "Rolloup")
Still don't really get what Stencil is. Is it a actual single framework or a standard syntax that compiles to React, vue, .. component syntax? This talks about compiling JSX to bindings avoiding vdom diffing but as far as I know that is near impossible to do due to the variable nature of JSX..?
And just a wall of unhighlighted fixed with code is very difficult to compare the differences. And would rather see bundle size comparisons rather than 6 lighthouse screenshots.