<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Aditya Tripathi</title>
    <description>The latest articles on DEV Community by Aditya Tripathi (@adityatripathi).</description>
    <link>https://dev.to/adityatripathi</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F885593%2Ff7440435-1f6a-4746-9587-1e9eed58f1fb.png</url>
      <title>DEV Community: Aditya Tripathi</title>
      <link>https://dev.to/adityatripathi</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/adityatripathi"/>
    <language>en</language>
    <item>
      <title>Framework Wars Have Reached Runtimes: NodeJS, Bun, Deno</title>
      <dc:creator>Aditya Tripathi</dc:creator>
      <pubDate>Mon, 29 Aug 2022 08:42:38 +0000</pubDate>
      <link>https://dev.to/adityatripathi/framework-wars-have-reached-runtimes-nodejs-bun-deno-3di0</link>
      <guid>https://dev.to/adityatripathi/framework-wars-have-reached-runtimes-nodejs-bun-deno-3di0</guid>
      <description>&lt;h2&gt;
  
  
  The Framework Epidemic
&lt;/h2&gt;

&lt;p&gt;Angular, React, Vue, Remix, Svelte, and something new every coming day, JavaScript framework releases have become an epidemic to collapsing gravity of &lt;code&gt;node_modules&lt;/code&gt;, config files, and you as a developer. However, this epidemic doesn't stop there.&lt;/p&gt;

&lt;h2&gt;
  
  
  Runtime Wars
&lt;/h2&gt;

&lt;p&gt;Deno, another major runtime made yet again on Google's V8 engine using Rust programming language quickly gained traction the past year and was co-created by Ryan Dahl who wanted to correct the mistakes he couldn't reverse while making NodeJS which he announced at JSConf in 2018 in his talk "10 Things I Regret About Node.js".&lt;/p&gt;

&lt;p&gt;Coming forward to 2022, we've seen a new player in the market who has been gaining a lot of attention, Bun. It's created by Jarred Summer using the Zig programming language but the one thing that differentiates this from all other runtimes is the use of JavaScriptCore, Apple's JavaScript engine which is used in Apple Software rather than the well-known and popular competitor V8 by Google, offering better performance than V8 from the get-go.&lt;/p&gt;

&lt;h2&gt;
  
  
  Runtime Comparison
&lt;/h2&gt;

&lt;p&gt;Let's compare these three runtimes to see what they offer.&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Feature&lt;/th&gt;
&lt;th&gt;NodeJS&lt;/th&gt;
&lt;th&gt;Bun&lt;/th&gt;
&lt;th&gt;Deno&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;JS Engine&lt;/td&gt;
&lt;td&gt;V8&lt;/td&gt;
&lt;td&gt;JavaScriptCore&lt;/td&gt;
&lt;td&gt;V8&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Top-level awaits&lt;/td&gt;
&lt;td&gt;Only ESM&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Built-in .env, .toml support&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Native TypeScript support&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Single executable&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Built-in test runner&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;tsconfig.json support&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Built-in linter &amp;amp; formatter&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Permission system&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;No&lt;/td&gt;
&lt;td&gt;Yes&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Module support&lt;/td&gt;
&lt;td&gt;CJS, ESM&lt;/td&gt;
&lt;td&gt;CJS, ESM&lt;/td&gt;
&lt;td&gt;ESM&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Languages&lt;/td&gt;
&lt;td&gt;C, C++&lt;/td&gt;
&lt;td&gt;Zig, C++&lt;/td&gt;
&lt;td&gt;Rust&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;It goes way beyond this comparison but this should give you an overview of what each of them has to offer.&lt;/p&gt;

&lt;h2&gt;
  
  
  Benchmarks
&lt;/h2&gt;

&lt;p&gt;One main reason why Bun has been gaining traction is due to its high performance which was unheard of in the JS community. Let's see some benchmarks to see how NodeJS, Bun, and Deno compare in terms of performance.&lt;/p&gt;

&lt;h3&gt;
  
  
  React Server-side Rendering
&lt;/h3&gt;

&lt;p&gt;HTTP requests per second (Linux AMD64)&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--hIQOla6q--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zuk6ad50yjkhlqctd7y7.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--hIQOla6q--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/zuk6ad50yjkhlqctd7y7.png" alt="Server-side rendering React" width="352" height="272"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Loading Large Tables using SQLite
&lt;/h3&gt;

&lt;p&gt;Average queries per second&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--rw82A6i1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9hsz1swm3tui8g9kbzd3.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--rw82A6i1--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9hsz1swm3tui8g9kbzd3.png" alt="Loading Large Tables using SQLite" width="375" height="267"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Hashing
&lt;/h3&gt;

&lt;p&gt;Operations per second&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--VpCP4CkE--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jt6dzfwk6a92lcmldeg9.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--VpCP4CkE--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jt6dzfwk6a92lcmldeg9.png" alt="Hashing" width="368" height="266"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;h3&gt;
  
  
  Conclusion
&lt;/h3&gt;

&lt;p&gt;Bun isn't just fast in terms of code performance but the whole developer environment feels snappy. You can install and uninstall any package within sub-second times. That might not sound much to you if you're coming from a different programming language but for users of NodeJS, that was unimaginable before.&lt;/p&gt;

&lt;h2&gt;
  
  
  Final Thoughts
&lt;/h2&gt;

&lt;p&gt;Competition promotes innovation and having these three compete to be the best and most popular is highly beneficial for developers. Most of these runtimes offer inter-compatibility with only slight changes so we users will never have to modify our code more than a few lines besides deno which might require a bit more work but that should be fairly simple.&lt;/p&gt;

&lt;p&gt;Bun and Deno are both private companies that have received funding from venture capitalists so they're here to stay for at least a few years and have time to create a place for themselves in the market. Node on the other hand is handled by the OpenJS Foundation.&lt;/p&gt;

&lt;p&gt;Deno's business model is hosting JS, TypeScript and, WebAssembly serverless functions on the edge and Jarred (creator of Bun) has shared similar plans along with continuous integration for backend and frontend applications on the edge for Oven's (Bun's parent company) future and sustainability.&lt;/p&gt;

&lt;p&gt;Let's see how these things progress and where the community goes with all this competition and hype.&lt;/p&gt;

&lt;p&gt;If you like what you read, you can support me by following me on &lt;a href="https://twitter.com/AdityaTripathiD"&gt;Twitter&lt;/a&gt;. Thank you!&lt;/p&gt;

</description>
      <category>javascript</category>
      <category>node</category>
      <category>news</category>
    </item>
  </channel>
</rss>
