million
bun
Our great sponsors
million | bun | |
---|---|---|
48 | 286 | |
15,128 | 70,251 | |
4.7% | 2.6% | |
9.7 | 10.0 | |
17 days ago | 3 days ago | |
TypeScript | Zig | |
MIT License | - |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
million
-
Show HN: Million Lint – ESLint for Performance
Hey HN! Founder of Million – We’re building a tool to that helps fix slow React code. Here is a quick demo: https://youtu.be/k-5jWgpRqlQ
Fixing web performance issues is hard. Every developer knows this experience: we insert console.log everywhere, catch some promising leads, but nothing happens before "time runs out." Eventually, the slow/buggy code never gets fixed, problems pile up on a backlog, and our end users are hurt.
We started Million to fix this. A VSCode extension that identifies slow code and suggests fixes (like ESLint, for performance!) The website is here: https://million.dev/blog/lint
I realized this was a problem when I tried to write an optimizing compiler for React in high school (src: https://github.com/aidenybai/million). It garnered a lot of interest (14K+ stars) and usage, but it didn't solve all user problems.
Traditionally, devtools either hinge on full static analysis OR runtime profiling. We found success in a mixture of the two with dynamic analysis. During compilation, we inject instrumentation where it's necessary. Here is an example:
function App({ start }) {
-
Million 3.0: All You Need To Know
To be honest, it fills me with great joy to finally be able to witness the launch of the 3.0.0 major release of Million.js; this is something that has been talked about since maybe July 2023, but, Aiden Bai finally assembled a team to get it out there and just last week on the day 2 February as at 8:00 am PST (Pacific Standard Time) Million v3 was released!!
-
React Jam just started, making a game in 13 days with React
>> React is not traditionally used for making games, but that's part of the fun and the challenge. R
> MS Flight Simulator cockpits are built with MSFS Avionics Framework which is React-like and MIT licensed:
https://github.com/microsoft/msfs-avionics-mirror/tree/main/...
preactjs may or may not be faster: https://preactjs.com/
Million.js is faster than preact, and lists a number of references under Acknowledgements: https://github.com/aidenybai/million#acknowledgments
> We use a novel approach to the virtual DOM called the block virtual DOM. You can read more on what the block virtual DOM is with Virtual DOM: Back in Block and how we make it happen in React with Behind the block().*
React API reference > Components > Profiler:
-
My Journey to Accelerate Load Times in Heavy Frontend
Consider replacing the default virtual DOM with an alternative solution. For instance, Million.js
-
Welcome to the dark side. Ree.js awaits you!
@aidenybai 's Millionjs
-
Show HN: I made a tool that makes React faster automatically
In brief: I'm Aiden, 18, and have spent the past 2 years of high school working on Million.js, an open source React alternative with 11K stars on GitHub and hundreds of thousands of npm downloads.
Recently, I released automatic mode, which detects slow React components and automatically optimizes the reconciliation phase. It's still in beta but chugging along. It's around 70% faster than React on the JS Framework Benchmark and you can see how I did it here: https://million.dev/blog/virtual-dom
Interested? Check it out here: https://million.dev
-
What are your thoughts on Preact Signals? I've thoroughly enjoyed it but am now thinking of dropping it because it results in a fat stack of issues in the Next 13 server logs and because Dan Abramov himself advised against it. Nothing's broken, but it doesn't feel like it makes sense to use anymore
Either that or add signals to the library itself. I don't get why it isn't in there when a ton of React's competitors are either using signal-like behavior or forgoing the clearly-obsolete way React handles its VDOM. When a high schooler can create something to make the library faster, you know that the core team is either prioritizing the wrong things or someone managing React is too prideful to admit that a lot of what worked a decade ago doesn't work today.
- Million – Fast and lightweight virtual DOM that makes React up to 70% faster
-
Introducing Million.js - A Lightning-fast Virtual DOM for React!
Reference: https://million.dev/
- React Up to 70% Faster
bun
-
React Server Components Example with Next.js
At Node Conference 2023, Jarred Sumner (creator of Bun) showed a demo of server components in Bun, so there is at least partial support in that ecosystem. The Bun repo provides bun-plugin-server-components as the official plugin for server components. And while I haven’t looked at it in-depth, Marz claims to be a “React Server Components Framework for Bun”.
- Bun – A fast all-in-one JavaScript runtime
-
From Node to Bun: A New Dawn for JavaScript Engines?
Continuously evolving, Bun is currently optimized for MacOS and Linux, with ongoing efforts towards Windows compatibility. Tailored for resource-constrained environments like serverless functions, it emerges as an ideal solution. The Bun team is committed to achieving comprehensive Node.js compatibility and seamless integration with prevalent frameworks. For those intrigued by Bun's potential and want to give it a try, more information is available on its website at https://bun.sh/.
-
Bun - The One Tool for All Your JavaScript/Typescript Project's Needs?
Let’s say you are interested in learning more about Bun and probably give it a try. Bun has a website, where you can learn more about Bun and its features (including all the benchmark data captured in this issue), and here is the link.
-
Bun 1.1
Looks like it, it seems the 2% are mostly odd platform specific issues that the authors' did not deem very important (my assumption for the release happening anyway). AFAIK this[1] PR tries to fix them.
-
Bun-ify Your Project
Bun has a solution for it. First of all, it already has a list of trusted dependencies. For them, Bun will execute all necessary scripts by default. Otherwise, you can add it to trustedDependecies in your package.json file. In Bun community usage of trustedDependencies is a hot topic. There are several suggestions on how to improve it.
-
I have created a small anti-depression script
Install Node.js (or Bun, or Deno, or whatever JS runtime you prefer) if it's not there
-
JSR: The JavaScript Registry
I think maybe I was unclear. I'm talking about writing libraries that abstract across these differences and provide a single API, as sibling describes. I already know it's possible. I made a simple filesystem abstraction here[0] and a very simple HTTP library that uses it here[1]. They both work in Node/Deno and the browser. Unfortunately I ran into issues with Bun's slice implementation[2]. But I suspect there's a much better way of detecting and using the different backends.
[0]: https://github.com/waygate-io/fs-js
-
SelectorHound: The tool for Sniffing out CSS Selectors
For, for more speed (requires installing bun first):
-
OpenCommit: feature-rich CLI to generate meaningful git commit messages now supports local models via Ollama 🤯🔫
OpenCommit is a CLI to generate commit messages, you can try it right now by running npx opencommit in any repo you have changed code in. I suggest you use bunx opencommit (install Bun) or install OpenCommit globally npm i -g opencommit and then run oco which is a shorthand.
What are some alternatives?
Vue.js - This is the repo for Vue 2. For Vue 3, go to https://github.com/vuejs/core
vite - Next generation frontend tooling. It's fast!
Alpine.js - A rugged, minimal framework for composing JavaScript behavior in your markup.
GORM - The fantastic ORM library for Golang, aims to be developer friendly
html2canvas - Screenshots with JavaScript
nvm - Node Version Manager - POSIX-compliant bash script to manage multiple active node.js versions
React - The library for web and native user interfaces.
fastify - Fast and low overhead web framework, for Node.js
Rete.js - Rete.js is a framework for creating visual interfaces and workflows. It provides out-of-the-box solutions for visualization using various libraries and frameworks, as well as solutions for processing graphs based on dataflow and control flow approaches.
go-pg - Golang ORM with focus on PostgreSQL features and performance
snabbdom - A virtual DOM library with focus on simplicity, modularity, powerful features and performance.
deno - A modern runtime for JavaScript and TypeScript.