Deno – A new Node.js?

Sampurna Gautam

Bachelor’s Thesis Degree Programme in Business Information Technology 2021

Author Sampurna Gautam Degree programme Business Information Technology Thesis title Number of pages Deno – A new Node.js? and appendix pages 46+ 2

JavaScript has been one of the most used programming language after its introduction 25 years ago. One of the most exciting features of JavaScript was its ability to write server-side scripts and with the introduction of Node.js it has never been the same. The amount of func- tionality that can be added to your script with or without the help of third-party modules has made Node.js a front runner in server-side development.

But in 2018 with the release of a new runtime engine called Deno which was introduced to tackle the shortcomings of Node.js and was shipped with many new exciting features and maximum emphasis on security, which interestingly is also an anagram of Node.

The objective of this research was to get an insight from the target group of this research about their opinions on Node.js and Deno the main question of this research paper was if Deno will replace Node.js and become the new Node.js.

An electronic survey was created and sent to the target group through different social media channels asking their opinions and experiences with the new Deno and Node.js for data collection. In addition to an initial survey a follow-up survey was also done with recommen- dation from the teacher and some of the participants from the initial survey Qualitative data collection was chosen for this research.

The conclusion derived from this research was that while with Deno you have access to all the new features like out of the box TypeScript support etc and very stern security protocol which can be considered as a right direction for server-side development but because of it not being around for a long time and much more work to be done for it to be ready for pro- duction it’s a bit immature to replace Node.js which definitely has been around a longer time than Deno and because of how popular it is ,it has been able to set a standard for its users because of its settled ecosystem so for the time being Deno is to be considered as a rival and an alternative solution to the needs of server-side development and not necessarily a replacement.

Keywords JavaScript, Programming, Learning, JavaScript Frameworks, JavaScript Libraries, ECMAS- cript, Deno, Node.js, security, server-side.

Table of contents

1 Introduction ...... 1 1.1 Research Background ...... 1 1.2 Research Objectives ...... 2 1.3 Target Audience of Research ...... 2 1.4 Scope of the Research ...... 2 2 Theoretical Background ...... 3 2.1 Node.js ...... 3 2.1.1 History of Node.js ...... 4 2.1.2 Node.js Execution model ...... 5 2.1.3 Node.js Ecosystem ...... 7 2.2 Deno ...... 9 2.2.1 History of Deno ...... 14 2.3 Deno Vs Node.js Benchmarks ...... 16 3 Research Plan and Methodology ...... 22 4 Main research & Development ...... 24 4.1 Survey of the Students and Developers ...... 24 4.1.1 Initial Survey Questions...... 24 4.2 Analysis of the data ...... 26 4.2.1 Background of the target group ...... 26 4.2.2 Experience and Impressions of Deno ...... 31 4.3 Follow up questions and responses ...... 35 4.3.1 Follow-up questions ...... 35 4.3.2 Follow-up question responses ...... 36 5 Evaluation ...... 40 5.1 Impression of Deno ...... 40 5.2 For now, Node.js or Deno? ...... 41 5.3 Deno’s Future prospect ...... 41 5.4 Validity of the results ...... 42 5.5 Reflection on the thesis process ...... 42 5.6 Further research and potential areas of improvement ...... 43 6 Conclusions ...... 44 References ...... 45

1 Introduction

1.1 Research Background

The programming language JavaScript has been around for a good strong 26 years after its first release in September 1995 which was developed for Netscape Communications Corporation internally by . Created as a for adding interac- tivity to a static web page. In the 25 years of its existence, it has been able to extend its original limitation to being one of the central pillars of the web.(Eich 2008) In the past 25 years, it has evolved from its small scripting tool to a language that powers many of the powerful large-scale apps that we use in our daily life like PayPal and LinkedIn.

In a moderately brief timeframe of its existence, a huge number of JavaScript frameworks have popped-up that has helped programmers to build complex web apps in a short period of time. But with the evolution and rapid development of the language the complexity, productivity and quality all have been increased and the way it’s moving forward sky is the limit.

Intended initially for the frontend side of development practice, JavaScript hasn’t been lim- ited to that and over the years has spread its wings to backend development, mobile and desktop apps. JavaScript runs on the browser with its browser engine of respective browser, but with the possibility of writing JavaScript outside of the browser arose the creation of various runtime or environment that helped software developers run JavaScript scripts out- side of the browser to produce dynamic content. One of the most popular and widely used examples of a JavaScript runtime is Node.js.

Node.js is an open-source server-side asynchronous event-driven JavaScript runtime that was built on chrome’s V8 JavaScript engine the same one used on the Google’s famous browser chrome. Developed by Ryan Dahl in 2009 Node.js has quickly been one of the most used interpreters for JavaScript. What led to the rise of Node.js was that Netscape Livewire which could create webpages by using server-side JavaScript failed and years later Node.js Introduced and server-side JavaScript has never been the same again.(Nodejs.org 2021)

Various other alternatives to Node.js has been introduced over the years serving different purposes and functionality but no one has even come close to Node.js considering the overall performance but in mid-2020 by the creator of Node.js a new runtime environment was released called Deno ,which ran on the same chrome’s V8 engine is basically a better

1 version of Node as Ryan Dahl himself who compiled all the regrets, he had on Node.js and created Deno .

1.2 Research Objectives

While Node.js has been the leader in server-side JavaScript for more than 10 years now but now there is a competitor in the market and moreover the competition was released by the same guy who was behind the development of Node.js. So, this research aims to shine a light on Deno and Node their similarities and differences while creating a simple REST API and discussing the rumour that is Deno is the new Node.js.

1.3 Target Audience of Research

The targeted viewers of this research paper will be Developers and students that use Ja- vaScript as their main language of trade or studies.

I expect that this research would benefit the students the most as it would give them an insight on the difference of those two runtime environments and since Deno is compara- tively newer than Node it would help them to understand Deno in a simpler way and also could be a building block for them if they create something in Deno for their own projects.

1.4 Scope of the Research

There was a lot of choices when it came to researching about JavaScript runtimes environ- ment because over the years there has been a fierce competition between browsers with their runtime engines to offer their users the best experience and performance. And for this research I have chosen two environment that runs on the same chrome’s V8 JavaScript engine. This moreover allows the content of the research to be more specific and allows the results to be clearer to the target audience.

Node.js was chosen because it is one of the most used server-side runtime environments for JavaScript these days. Many large-scale apps that we use in regular basis like Netflix, twitter etc are courtesy of Node.js.

Deno was chosen because it runs on the Google’s V8 engine which is same engine that is used by Node.js and was created by the guy who was also behind Node.js. i.e., Ryan Dahl Deno is new, and its new features has brought in many possibilities to fix the wrongs of Node.js.

2

2 Theoretical Background

2.1 Node.js

JavaScript now is 26 years old compared to JavaScript Node.js is just 12 years old, but it seems like it has been around the entire time. Node.js had the perfect timing to come up to the world of web that led to the rise and popularity of the engine. Developers had just started to take JavaScript more seriously as a language because the applications developed in the “web 2.0” like Gmail and Flickr that showed the world what modern new and innovative experience in the web could be making Node one of the most exciting new platform to de- velop new applications on the web.(Nodejs.dev 2021)

In simple worlds Node.js can be stated as a standalone JavaScript Virtual machine, with extensions making it suitable for the most common purposes of programming and is de- signed for extreme scalability in networked applications with a combination of server-side JavaScript, asynchronous Input/ Output (I/O). Node.js has been rapidly growing and all the growth has seen it as a new alternative to building web applications to the pre-existing lan- guages or frameworks like Apache ,java Php , python etc. What makes Node.js different from all those aforementioned stack or languages is because of its event-driven architecture the memory footprint is low, the programming model is simpler and the latency profile under load is better. (Herron 2013)

Node has quickly become one of the most used platform for writing JavaScript applications outside of the browser, Node doesn’t have (DOM) built in it and doesn’t necessarily have the capabilities of a normal browser, but an external DOM that can be used by adding JSDOM and some browsers have their Node based wrappers to run in their browser engines. Node has a low-level network layer which makes it easy to use. The built-in HTTP modules makes it really use to write a HTTP based server or a client in mere few lines of code.(Herron 2013)

Node.js has introduced a lot of interesting capabilities and innovative approach to the world of web for the developers to think outside of the box and making it easier the things which were probably not as easy before. There are quite a few capabilities that made Node as good or as popular as it is now, like: − Use of command line tools − Lookup feature for Domain Name System (DNS) − Access to the

3

− Dealing with binary data with buffer object. Etc (Herron 2013)

2.1.1 History of Node.js

Ryan Dahl frustrated over the inability of the existing Apache’s server’s shortcomings to scale concurrent connections into the thousands. Even though there were many attempts made in the mid-90s specially Netscape’s Livewire Pro Web but still unsatisfied with the existing problems Node.js was created in 2009. With the release of Node.js in the same year the first form of Node was also created.(Nodejs.dev 2021)

In the year 2010 Express was born which is one of the most used Node.js web application framework that provides set of features to develop web and mobile applications. Making a robust API was made quick and easy because of its fast unopinionated and minimalistic framework.(expressjs.com 2021) and in the same year socket.io was released too . Socket.io is a real-time application based on nod e it enables real-time, bidirectional, and event-based communication. It is multiplatform , multidevice and multi browser compatible which focuses on reliability and speed.(Arrachequesne 2021)

2011 was a big year for Node.js as Node.js was gaining market and big companies like uber and LinkedIn started using it. Node package manager released version 1.0. HAPI was born the same year too. HAPI is an alternative to Express and is also a framework for building applications and services. The Adoption of Node.js was continued in a good fashion in 2012. Ryan Dahl left Node in January of 2012 believing that the Node project was “complete”. Following the trend of adaption of Node.js, Ghost became the first big blogging platform in 2013 to start using Node.js. Koa another alternative to express and Hapi was born the same year. Koa was built by the same team behind express and aims to be a more lightweight and a powerful foundation for multiplatform applications and . (Nodejs.dev 2021)

One of the biggest forks for Node.js was in 2014 when io.js released version 1.0.0 and the reason it was considered the biggest if not the biggest achievement for Node.js was be- cause of the availability of the features of ECMAScript 6 without using any flags. New core modules were introduced as well without the use of Node’s package manager (). Node.js version 4 was released in the year 2015 despite not have released versions 1,2 and 3. In the same year Node.js foundation was born, NPM introduced private modules that allowed sharing of code with your teams, users, or organization. And the big event of that year was when IO.js merged back to node. (Nodejs.dev 2021)

4

Release of Node.js’s version 6 happened in the following year of 2016. One big incident that happened the same year was the left-pad incident , explaining the incident briefly npm said that there was a dispute over a package name , and resulting in a opensource devel- oper unpublishing all of his 250+ packages from NPM, among which was one package called left-pad , after unpublishing the package it broke the other packages that was de- pended on it and some bigger packages and companies using some package depended on that reported hundreds of error in a single minute(blog.npmjs.org 2021).

Yarn was released in 2016, Yarn is a package manager like npm which was released by Facebook to overcome the shortcomings of performance and security issues in npm at that time. Following the release of Yarn in 2016 npm emphasised more on security since there was a new competition for node’s package manager market meanwhile continuing the Node.js released version 8 in 2017. The same year npm hit 3 billion downloads every week. engine used my Node.js introduced Node.js to its testing suite. (Nodejs.dev 2021)

On the following years from 2017 to 2020 Node.js released in an average of 2 new versions so Node version 10 ,11,12,13,14 and 15 were released in year 2018,2019 and 2020 re- spectively. (Nodejs.dev 2021)

2.1.2 Node.js Execution model

As Node.js comparatively new considering all the other platforms used for server-side pro- gramming even though it follows the same execution model that JavaScript uses in the browser what sets it apart is that it has non-blocking, which is also known as asynchronous ,single-threaded , event-driven execution model.

Non-blocking or asynchronous operation in Node.js means that, it recognizes that some programmes take most of their time to wait for the other processes to complete too such as I/O operations such as disk access and network requests. What Node.js does is that it doesn’t wait for the I/O process to complete making it non-blocking which initiates the op- erations and leaves the complete the task while returning immediatealy without any result while the process runs in the non-blocking mechanism.(Cummings 2016)

5

Figure 1 : Example of Non-blocking code in Node.js

This figure is an example of how non-blocking asynchronous code runs on Node even when using a blocking code setTimeout() is used which normally blocks the code to run for the time specified and complete it first which is 5 seconds in this example but in node it registers this as a future event and lets the program to run making Node.js asynchronous.

Figure 2: Event driven architecture in Node.js (tutorialspoint.com 2021)

The Event-driven architecture in Node.js explains how the operation are supposed to run in a schedule ,because Node.js has a built-in event loop which decides what piece of code to

6 run next which in most of the cases is a callback function which is ready to run in response to some other event. This event-driven architecture helps Node.js to run asynchronously providing a consistent approach and helping applications by managing their schedule.

Last but not the least Node.js is single threaded which means that all the operations are handled in a single thread with shared resources and because there is only one thread handling the execution of all the processes every bit of code is guaranteed to run without being blocked by other operation i.e. non-blocking or asynchronous operation removing the possibility of range of concurrency issues.(Cummings 2016)

2.1.3 Node.js Ecosystem

The built-in APIs in Node.js has provided us creating application with a very low-level core. Node applications use only a small amount of the available API’s directly and one reason for that is the amount of third-party library modules available often open sourced that pro- vide a higher level of abstraction for application development. Like java’s maven and .NET’s NuGet Node has its own package manager, npm.

The npm registry is a central repository for the packages that support a vast array of func- tionality that can be added to an application making it easy to use without any fuss. All the dependencies of the application are included in a single JSON file. The npm registry is considered as one of the top package mangers in the world and is already larger than the other package managers or repositories for various programming languages. One reason of npm being so huge is the community of Node.js, it has one of the most active community contributing to many repositories. The npm command line tool is the median to download and install packages to an application, most of the packages provide the command-line tools which can be run in the terminal whenever needed if installed globally.(Cummings 2016)

One of the most attractive features of the Node.js ecosystem is everything is written in Ja- vaScript and all the packages follow the same non-blocking API methods that Node.js has which makes it easy to build applications which are asynchronous throughout.(Cummings 2016)

7

Figure 3: Example of a npm package axios in npm directory (npmjs.com 2020)

The above figure shows where you can find all the details of a third-party module in npm’s official website. Here you can find the official documentation on how to use the respective package and who have been working on the dependency and also the official GitHub link to the third-party module code.

8

2.2 Deno

For about last 10 years up until 2020 when developers specialising on backend side of the development had Node.js as a favourite when it came to using JavaScript on the back end. Even the popularity wasn’t at the level as it is now in the beginning but slowly but surely, it’s gotten to a point where it has been the go-to JavaScript runtime for developers and as one of the widely used back-end technologies in the market. It has become almost the de facto choice for developers for writing APIs, because of the insane performance boost on the development side as well as the efficiency with very little effort. But after 10 years a new JavaScript runtime is available which is not only similar to Node and as the creator of Deno Ryan dahl says a better approach at solving the same problem. (Doglio Fernando 2020)

The work on Deno had been going on for a couple of years before its release in 2020 , Ryan dahl hinted that he was working on the prototype of Deno when he gave a talk in a confer- ence called “10 things I regret about Node.js”. He stated in the conference that his motiva- tion was very straightforward , he considered that Node.js has some very fundamental flaws that couldn’t be solve in the project, so he concluded that having a fresh start is the right way to fix things , not necessarily to redesign the language but the internal architecture in whole on how Node functioned and solve some of the requirements . One of the biggest and the first things Ryan changed in his new endeavour of Deno was the tech stack. While Node was written in C++ and was supported by for carrying out asynchronous I/O operations but for Deno he chose a newer approach and used Rust as the main develop- ment language and Tokio an async library built on top rust to carry out the asynchronous I/O operations. (Doglio Fernando 2020)

Deno aims to provide a fun, productive and quick scripting environment which can be used for a huge variety of basic and complex tasks. Ryan Dahl has made it very clear in his blogs that Deno is and always will be shipped to its users as a single file which ensures efficient distribution. Deno comes with its own bundler which creates a single consumable .js code transpiling the code if it’s written in TypeScript at the time of delivery and for later Deno has its own that compiles the code into a single executable binary.(Reichen Tim 2021)

Deno’s bundler helps Deno to act alike to a which is capable of fetching ex- ternal code to be executed. Also, in Deno without any help from other tools a single file is capable of defining complex behaviour. A complete HTTP server module can be added with a single line of code in Deno. (Dahl Ryan, Belder Bert, and Iwańczuk bartek 2020) .

9

Figure 4: Example of permission error in Deno

Code in Deno is executed in a secured sandbox like in a browser. Open network connec- tions and access to the hard drive cannot to be accessed without permission which removes he possibility of malicious attacks, this is one of the biggest security features of Deno. An- other feature of Deno is it’s out of the box support for . Typescript is a superset of JavaScript which needs to be compiled to run that enables its users to provide type infor- mation in their code. As Deno aims to be useful for wide range of problem domains, from complex backend logic to mere small line of code having support for typescript to check types becomes more important.(Dahl Ryan, Belder Bert, and Iwańczuk bartek 2020) .

Figure 5: A code snippet demonstrating top-level await in Deno

Another great functionality that Deno has is it’s top-level await functionality. When Node added the async/await clause, it started to become a common norm for developers to switch their promise-based approach to the async/await mechanism. The only issue was that every for the await clause to function it had to be a part of async function. Even though it’s been a few years that google v8 engine has support for a standalone await clause, but Node hasn’t been able to adapt to it. But in Deno the top level await functionality comes in-built. The top level await functionality is helpful to write cleaner code and it enables the ability to await actions like connection to the server or the database on the very top level instead of wrapping them into an async function. The biggest change in Deno which Ryan considers to be a one of the most impressive feature is no more use of NPM , he considered npm and everything about it wrong, he didn’t like the fact that every module was inside a privately controlled centralized repository and it being too verbose to use. (Doglio Fernando 2020).

10

Up until few years ago developers had to add external libraries in top of JavaScript’s stand- ard library like jQuery to help everyone how worked and other helper methods to iterate over objects and over time library like Underscore, Lodash or any similar versions were added slowly to the standard library of JavaScript. And it will be a long time that we can build something without having to add some external module. With all that in mind Ryan Dahl created Deno’s standard library that provides developers with not just building blocks but a proper set of functions as a standard module that was and will be reviewed and audited by the Deno’s main team. (Rully Yulian 2020)

Figure 6: Deno’s standard library from Deno’s official website (deno.land 2021)

11

Built-in testing is one great example of benefit of Deno’s standard library , it’s built-in test runners helps execute test scripts written in JavaScript and TypeScript , the script is very familiar to the third-party libraries that are used in Node.js like jest and jasmine , and be- cause Deno uses URL for importing the dependencies , the test can be easily carried out just by pointing the test command to a remote test suite hosted somewhere online , with- out the need to run the test suit ourselves. (McKeaveney Martin 2020)

Figure 7: Example of a simple test script in Deno (McKeaveney Martin 2020)

In addition to Deno’s standard library Deno also supports other third-party modules that can be downloaded through other URLs such as GitHub, CDN and different private web servers. One big change to third party module system from Node.js to Deno is that their party mod- ules can be hosted anywhere unlike in Node where it has to be uploaded to the npm repos- itory.(Rully Yulian 2020)

12

Figure 8: Example of a third-party module called fuse in Deno's official Website (krisk 2020)

This figure is from Deno’s official website where the third-party modules are available it has the official documentation of the module also along with code for it and the link to the crea- tor’s official GitHub account.

13

2.2.1 History of Deno

Despite being a relatively new runtime and in the market still less than a year after Deno has been updated quite a few times different versions was released in the small time Deno has been out. On the 13th of May of the year 2020 Deno 1.0 was released, after almost two years after the famous talk by the creator Ryan dahl about the regrets he had for Node.js and the design flaws that was made while creating node. Deno’s first release had all the features from the aforementioned introduction.

After just 3 months of the release of Deno’s first version there was a big change in Deno’s hosting service for Deno scripts named Deno.land/x. Third party modules in this change was to be fetched from the S3 bucket where before the sourced was pulled from raw.githubusercontent.com. Another change in Deno.land/x was all of the files that was served from the repository were made immutable which means editing and deleting any content by the package author was not possible. (Bartek Iwańczuk, Ryan Dahl, and Luca Casonato 2020)

In the very next month of September Deno released version 1.4 skipping version 1.2 and 1.3. Version 1.4 claimed to be the largest feature release may by Deno till that date, features like support for WebSocket API was added which is available in all modern browsers which is used to communicate with the remote servers. (Bartek Iwańczuk, Ryan Dahl, and Luca Casonato 2020)

Automatic restart of the script on file change as well as getting summary of the test coverage was also added as a feature in this update. Small changes like adding colours to the console with very common CSS properties. Improvements to the Deno info was also done as well as there was an updated documentation in Deno doc. (Bartek Iwańczuk, Ryan Dahl, and Luca Casonato 2020)

On the month of October just a month after the release of version 1.4 Deno released version 1.5 very fast pace, this update brought in quite a few new features, past features stabiliza- tions and a ton of bug fixes. Deno’s improved bundling with the refactoring of the entire TypeScript compiler infrastructure led to increase in performance improvement by 3 folds while type checking the code and 15 times when using the --no-check command. Like in the browser Deno also added the web platform API’s alert, confirm and prompt. Improvements were made to the REPL like code syntax highlighting, top level await support and tab completion of objects properties and methods. (Bartek Iwańczuk, Luca Casonato, and Ryan Dahl 2020)

14

On the final month of December Deno released its final update of the year 2020 version 1.6.0 which featured multiple bug fixes as well as some major features. One of the biggest features was the built-in language support for Deno which meant that it provided fully inte- grated language support protocols for multiple code editors except the VSCode extension claiming that it was more feature rich than the available language support protocol. Code completions, hits on hover and Deno lint and Deno fmt integrations were added. Other fea- ture was the self-contained, standalone binaries for the build which helped building the Deno project into completely standalone . Deno also shipped version 1.6.0 with the latest version of typescript 4.1. (Luca Casonato, Ryan Dahl, and Bartek Iwańczuk 2020)

The release of version 1.7.0 in January 2021 brought in a few changes which contained a few new features, stabilizations and improvement to existing APIs and tooling. Improve- ments made to the Deno compile resulted in generation of binaries that were around 40- 60% percent smaller than any other previous versions. Deno also added more support for importing data URLs etc. (Bartek Iwańczuk and Luca Casonato 2021)

The latest and the up-to date version released by Deno was in the month of march of 2021 when Deno’s version 1.8.0 was shipped with an extensive amount very new features and stabilizations. Deno in this recent update has added experimental support for the Web Graphics processing unit WebGPU) API which will give the users a low-level, high perfor- mance and cross architectural way to program the graphics processing unit (GPU) hard- ware in a manner they desired with JavaScript. This API will give the users access to GPU rendering and other purposes that GPU computes from within Deno. Deno has also added the second most requested feature in Deno’s repository which is international components for Unicode (ICU) support for Deno and with the latest release of 1.8 Deno has provided full support for ICU. All the JavaScript APIs that depended on ICU now matches the browser API.(Bartek Iwańczuk, Luca Casonato, and Ryan Dahl 2021)

The latest update also added more stability to import maps which removed the use of the --unstable flag while using --import-map and also added support for accepting URLs to load import maps from remote servers. Deno also has added more stability to Deno.permissions which is more user friendly because it is now able to request and revoke permission at runtime whereas before it could only be granted when the application was started. As Type- Script I sone of the most attractive features of Deno the latest release of Deno comes with the latest stable version of TypeScript 4.2.(Bartek Iwańczuk, Luca Casonato, and Ryan Dahl 2021)

15

2.3 Deno Vs Node.js Benchmarks

Deno and Node.js can be commonly used for constructing various backend services like from a very miniscule REST API server to a massive server with multiple features and mi- croservices and one thing is pretty clear that what Node.js can do Deno can do it too and it is vice-versa. One of the various ways of benchmarking the performance of both the runtime engines are by seeing their http performance. (denocode.com 2020)

When comparing the performance of both the runtime-engines without the use of any third- party libraries to provide a factual representation the performance and with the use of the very simple performance tester that ran on Deno which required no additional installation resulted on the following results .Also, to check the performance a small hello world server written in both Deno and Node.js was used to get the results. The performance test used for the comparison was executed in a MacBook pro which had 8G memory and ran on a Quad-core i5 processor and had no network delay in performing concurrent requests. Deno version 1.7.4 and Node.js version 15.8.0 was used for the purpose of performance comparison. (Choubey Mayank 2021)

Figure 9 : Hello world script in Deno(Choubey Mayank 2021)

Figure 10: Hello world Script in Node.js (Choubey Mayank 2021)

16

The test for the performance comparison was executed in three different scenarios with 1000 repetitions and with 1,10,25 concurrent connection to the server. The readings that had been taken into consideration were : Mean ,median , total time taken, requests per second , min , max the 1st and 3rd quantile . And the results that was acquired for all the tests were :

1. 1 concurrent connection

Here are the results that was obtained with 1000 repetitions i.e., 1000 requests :

Figure 11: Performance comparison between Node.js and Deno with a single concurrent connection and with 1000 repetitions The more lower the number the better the perfor- mance (Choubey Mayank 2021)

17

Figure 12: Details of every 10% quantiles of the test for performance comparison between Node.js and Deno with single concurrent connection. The lower the number the better the performance. (Choubey Mayank 2021)

In this performance comparison with a single concurrent request and with 1000 repetitions overall including the 1st quantile and 3rd quantile of the repetition showed that Deno per- formed better in comparison to Node.js and resulted in Deno being 13.34% faster in com- parison to Node.js. And performing better in every 10% quantile of the test . (Choubey Ma- yank 2021)

2. 10 concurrent connections

Here are the results that was obtained with 1000 repetitions i.e., 10000 requests :

18

Figure 13:Performance comparison between Node.js and Deno with 10 concurrent con- nections and with 1000 repetitions .The more lower the number the better the performance. (Choubey Mayank 2021)

Figure 14:Details of every 10% quantiles of the test for performance comparison between Node.js and Deno with 10 concurrent connection. The lower the number the better the per- formance. (Choubey Mayank 2021)

19

When the test was carried out with 10 concurrent requests and with 1000 repetitions Node.js had the better performance in all the readings including the 10% quantile of the readings, Deno underperformed in all the readings and was 6.25% slower comparing to Node.js. (Choubey Mayank 2021)

3. 25 Concurrent connections

Here are the results that was obtained with 1000 repetitions i.e., 25000 requests :

Figure 15:Performance comparison between Node.js and Deno with 25 concurrent connec- tions and with 1000 repetitions .The more lower the number the better the performance. (Choubey Mayank 2021)

20

Figure 16: Details of every 10% quantiles of the test for performance comparison between Node.js and Deno with 25 concurrent connection. The lower the number the better the per- formance. (Choubey Mayank 2021)

When test was carried out with 25 concurrent connection to the server and 1000 repeated requested the results there were mixed results but all in all Deno performed very well in most of the readings and showed good results in the upper quantiles but Node.js had a slighter better performance on the lower quantiles . Deno was found out to be 8.5% faster compared to Node.js with 25 concurrent requests.

The overall analysis of this small-scale test even though the difference wasn’t that noticea- ble Deno showed more consistent performance and faster performance for the hello world script in high load . (Choubey Mayank 2021)

21

3 Research Plan and Methodology

For the collection of data for this research qualitative data collection approach was chosen. Qualitative research was chosen because of its simplicity and assistance for identifying be- haviours and patterns among other things to explain the reasons behind a pattern and ex- periences. One of the biggest reason to choose a qualitative approach for data collection was how close I would be involved in the whole research process and its ability to reject or support the hypothesis presented in this research. My active involvement in the whole re- search process also is of the exciting feature of quantitative data collection because without the participation of the researcher there is no data. (McLeod Dr. Saul 2019)

Another reason why qualitative research was chosen was because it aims for objectivity meaning there is no bias on the responses or data where the respondent has full control over their opinion of responses. Qualitative data collection seeks to explain how and why a particular phenomenon or behaviours as such occurs in respect to the context and also can be used to generate further questions or new hypothesis from the gathered data. The fact that the qualitative data collection is endlessly creative and allows the researcher to interpret the data and construct the result of the data in a way that makes sense to the reader. (McLeod Dr. Saul 2019)

With the end goal of developing deep understanding of the research questions from an individual viewpoint in mind electronic survey was the best method selected for data collec- tion because of its simplicity to collect efficient data and the easiness of getting response electronically without siting down for an interview and writing down the answers. This also made it easier to reach a larger number of the target group for responses and with the help of google forms accurate expression of the collected data was made very easy. Online survey was also chosen because of its ease of access feature and the respondents are not pressurized to answer all the questions so they could just answer the questions that they were comfortable answering with. No further follow up will be done with regarding the an- swers provided by the target group.

And as far the target group for collecting data goes students and individuals that are cur- rently employed or unemployed but active in the software development scene were chosen for this research. Front end side of development and other frameworks or dependencies that work with either Node.js or Deno were also discarded for the discussion.

This research paper aims to raise, explore, and find answer the following questions:

22

1. As the Deno community and influence in software development industry is growing

what are their reservations to learn a new stack.

2. Concerns over security between Node.js and Deno.

3. For the Developers working the big question will be has Deno had an any impact in

their working lives.

3.1 Impression on the features of Deno.

3.2 What are the good the bad and the ugly about Deno and Node?

4. If they think Deno in near future will replace Node.js.

The results of this data collected from the respondents of this survey will be analysed to see what kind of experience the target group has with Node.js and if they have had any experi- ence with the more recent Deno and opinion about if they think that Deno will replace Node.js.

23

4 Main research & Development

4.1 Survey of the Students and Developers

The survey for this research process was designed in such a way that it would bring out all the experiences and sentiments of the respondents. This set of questions were prepared to get maximum amount of data needed for justifying the hypothesis without any bias. The questions are made in such way that you can get a good understanding of the respondent’s background slowly moving towards their experiences with Node.js and Deno and then finally to the opinions over Node.js and Deno which I think will provide an in-depth insight to the respondent’s attitudes.

The designed survey was sent to the target group using avenues such as the WhatsApp group for the students ,Free code camp forum and friends that are working in the software development industry to gather all the data and the opinions of the target group towards Deno and Node.js.

Google forms was chosen for the electronic survey because of its various functionality and the ease of use to create a graphical representation of the results collected from the survey.

There was no sample size for the survey the answers to the survey were requested through multiple channels so the results of the survey were limited to the free will of the individuals of the target group who were keen and ready to fill the survey , thus the results and data obtained from this research questions cannot be used to express the feelings and experi- ences of the vast software development community .

As per the recommendation of the teacher a follow up interview was done personally with few of the individuals who responded to the initial survey if they thought some questions were to be added to get a better insight of the topic. The questions and responses acquired through the follow up are added to the bottom of the development part.

4.1.1 Initial Survey Questions

The questions listed below are the question provided for the survey. The questions that are marked with a (X) was not considered as a mandatory question.

− Are you a Studying or Working at the moment of this survey?

24

− Have you any experience with JavaScript?

− How long have you been working with server-side JavaScript? (in years)

− Have you worked with Node.js, How long? (in years)

− Have you worked with Deno, How long? (in years)

− How did you first hear about Deno?

− Did you know that both Deno and Node.js are JavaScript runtime engines not a

language or a framework?

− Have you used TypeScript before?

− What are your thoughts on the out of the box support for TypeScript in Deno?

− With all the rumours going around Deno being the next big thing after Node.js

how willing are you to learn it if you haven’t yet?

− If you have already used Deno for whatever purpose how has the experience

been compared using Node.js? (X)

− With regards to the bold statement made by Ryan Dahl the creator of Node and

Deno about his concerns over security in Node, how concerned are you? (X)

− As you know the node_modules are one of heaviest objects on earth, what are

your thoughts on Deno’s ES6 import module with URLs?

− How helpful do you think the top-level await functionality supported by Deno is

going to be?

− Deno runs on sandbox so it requires permissions for file, network, and environ-

ment access whereas Node.js can access whatever the user can access, how

important of a feature is this concerning security?

− The biggest question of all, do you think Deno will replace Node.js, if so why?

(X)

25

4.2 Analysis of the data

For the 16 questions which was sent to the target group 25 responses were collected and below is the representation of the data collected with the help of google forms, which are grouped in 2 categories the background of the target group and impression of Deno and its features.

4.2.1 Background of the target group

Question 1 to 8 were designed and chosen to get the knowledge of what the background of the respondents were, and the responses provided by the respondents are presented graphically and discussed below:

Figure 17: Response on question about current status.

Out of the 25 responses 11 of the respondents were employed in some form or the other, a good 44% were actively working, 36% of the respondents or exactly 9 of the respondents were attending school at the time of this survey. And the rest 20% or 5 individuals that submitted a response to the survey were unemployed.

26

Figure 18: Response on experience with JavaScript

23 (92%) respondents out of all the 25 responses received had have an experience working in JavaScript just 2 of the respondents hadn’t had any form of experience with JavaScript.

How long have you been working with server-side JavaScript?(In years ) 25 responses 8 7 7 6 6 5 4 3 3 3 3 2 2 1

Numberresponses of 1 0 0 1 2 3 4 5 6 Years of experience

Figure 19: Response on experience with server-side JavaScript

Among all the 25 respondents to the survey there was an average of 2.7 years of experience and all of the respondents except 3 individuals who hadn’t had any experience of server- side JavaScript had at least 1 year of experience. There was one individual who had 6 years of experience with JavaScript which was the highest among the respondents.

27

Have you worked with Node.js, How long ? (in years) 25 responses 9 8 8 7 7 6 5 4 4 3 3 3

Number of responses Numberresponses of 2 1 0 0 1 2 3 4 Years of experience

Figure 20: Response for question about experience with Node.js

Like the previous questions this question also had 25 respondents too. On an average the respondents had 2 years of experience in Node.js, Like the response from before 3 individ- uals had no experience whatsoever with Node.js, 8 respondents had 2 years of experience and 3 individuals who had 4 years of experience, which was the highest.

Have you worked with Deno, How long ? (in years) 25 responses 14 12 12

10

8 7

6 5

4 Number of responses Numberresponses of 2 1

0 0 0.5 1 2 Years of experience

Figure 21: Response for question about experience with Deno

For the question 5 almost half of the respondents didn’t have had any experience with Deno 12 respondents to be precise, and the other 12 out of the 25 respondents had either half a

28 year or almost a year experience with Deno. 1 individual had 2 years of experience with Deno which was the maximum among the respondents.

How did you first hear about deno ? 25 responses

4% 4% 4% 24%

12%

4%

4%

20% 8%

8% 8%

Youtube Google Ryan Dahl's talk School Some blog Reddit can't remember this survey LinkedIn Never heard Friends

Figure 22 : Response for question about their knowledge on Deno

For the question 6 presented in the survey there was a vast array of responses most of the respondents has some idea of what Deno is through different channels on the internet, like google ,YouTube and reddit but not limited to those , some heard about it from friends or at school and only 1 respondent had never heard of Deno.

29

Figure 23: Response for question about runtime engines

For one of the controversial question that could define the knowledge of the target group the response provided by the individuals were mostly positive, 64%(16 people) of the respondents knew that Deno and Node are runtime engines for JavaScript rather than a framework or a language and the rest 36%(9 people) just like me before starting this re- search thought it was either a language or a framework.

Figure 24 : Response for question about experience TypeScript

Like the answer to the question 7 this was exactly similar, 16 individuals that constituted 64% of the responses had have used typescript before and the rest 9 people who consti- tuted the rest 36% of the responses have had no experience with TypeScript.

30

4.2.2 Experience and Impressions of Deno

Question 8 to 16 were designed and chosen to get the knowledge of the experience and impressions of the target group with either Nodejs or Deno, and the responses provided by the respondents are presented graphically and discussed below:

Figure 25 : Response for question about TypeScript support

Just as expected all of the respondents who were just divided by it being either good or very good were very happy with the addition of typescript out of the box for Deno , none of the respondents thought it was bad that Deno had TypeScript support .

Figure 26 : Response for question about their opinion on their learning interest

The response of the individuals to the question if they are willing to learn Deno at some point with the rumours it being the next big thing most of the respondents 18 individuals

31 were willing to learn Deno and the rest 7 respondents out of 25 were not willing to learn Deno.

Figure 27 : Response for question about their experience with Deno compared to Node.js

On the questioning of the individuals if they had used Deno already and what their experi- ence was, there were 16 responses provided. Out of the 16 responses 7 individuals deemed their experience with Deno has been very good. 5 people responded that they had a good experience ,3 of the respondents had okay experience and 1 out of the 16 had a bad time with Deno.

Figure 28 : Response for question about opinions over security

Ryan Dahl when giving his talk about 10 regrets he had in Node.js stressed a lot about the concerns he had for the security in Node.js, upon questioning the same question to the

32 target group there was a mixed response on how concerned they were. 42.9% (9 people) were very concerned about the security in Node.js, around 38.1% (8 people) believed they were concerned too the rest 19% (4 people) out of the 21 responses were not concerned about security at all.

Figure 29 : Response for question about opinions on node_modules

Whether it is in working life or student or just an hobbyist we all know that node_modules that come up with creating with a Node.js project are one of the most annoying things ever ,especially if you forget to add node_modules to the .gitignore file before uploading it to git , when asked about what they thought about Deno’s es6 import module with URLs out of the 21 responses 11 people which was half the respondents expressed a relief from node_modules , 8 people said that they’re glad that node_modules weren’t there anymore, 2 of the individuals believed that the addition of import of es6 module with URLs made the code more complicated.

33

Figure 30: Response for question about Deno’s top-level await feature

Deno added the top-level await functionality as a feature which removed the need of async clause for the promises, upon asking the thoughts of the target group on how helpful this functionality is 88% (22 people) expressed that this was very helpful and the rest 12%(3 people) out of the 25 responses believed it not to be helpful.

Figure 31 : Response for question about permissions and security in Deno

One other concern Ryan Dahl presented in his talk was the amount of access Node.js had without permission to access file, network and environment without any permission , Deno has to ask permission to the user for access ,upon questioning the target group on how important this feature was concerning security , 66.7%(16 people) out of the 24 response provided for this question believed that it was a very important feature concerning security , the rest of the 33.3%(8 people) believed that it was important , none of the respondents expressed that it was not an important feature.

34

Figure 32: Response for question If Deno would replace Node.js

The final question asked to the respondents for this survey was if they thought that Deno will replace Node.js the answers were divided in a good manner. 43.5% (10 people) thought it was too early to say that if Deno will replace Node.js. 21.7% (5 people) believed that it that Deno will eventually replace Node.js. The same amount of people believed that Deno is definitely replacing Node.js. A small percentage of the target group 13% (3 people) to be exact expressed that Node.js will not be replaced by Deno. There were 23 respondents to this question.

4.3 Follow up questions and responses

These are the question some of the respondents acquired through follow up personal inter- view deemed important to the research, the questions and responses are presented below. These questions were not added initially because of the responses already provided to the initial survey. Same channels for collecting the data were used as before to get the re- sponses for the follow up survey.

4.3.1 Follow-up questions

The questions which were suggested by few of the respondents for further help and clarifi- cation of this research 5 more questions were added and are listed below: − Which of the below listed features of Deno do you think gives or will give a compet-

itive edge over Node.js?

35

− Deno has a standard library for its users which is one of the most sought out feature

for JavaScript for example no more adding third-party dependencies for testing like

Mocha or jest to run tests, do you think this will encourage testing more?

− Deno's API is constructed to follow the browser's standard API. This means that the

users can go between each other easily, what are your thoughts on Deno's browser

support feature?

− Because of the active developer community some of the most used third-party li-

braries used in Node.js like Mongo DB, GraphQL, moment, axios etc has already

been ready for Deno, would this tempt you more to try Deno?

− Some of the companies have already started using Deno as their go-to choice for

server-side JavaScript do you think Deno is mature enough to be used for produc-

tion?

4.3.2 Follow-up question responses

For the follow up questions there were 23 responses made, all the responses are expressed below graphically:

Figure 33 : Follow up question response for Deno’s features

36

Most of the respondents thought at least one or more features of Deno would give it a competitive edge over Node.js. 11 of the respondents thought that built in testing and use of URLs for dependency management instead of node_modules were an exciting feature of Deno which also reflected the response to the initial survey where a good amount of respondents thought that it was a relief node_modules was gone. 9 individuals thought that top level promises are another exciting feature of Deno. 8 people were convinced that sup- port for TypeScript out of the box for Deno and permission for access as a security feature is a good prospect Deno.5 people thought Deno’s standard library is a great solution to the Node.js’s overwhelming need for dependencies. There were 23 respondents to this ques- tion.

Figure 34:Follow up question responses about testing in Deno

As testing is one of the most important aspect for any development task upon asking if the Deno standard’s library built in testing would increase the testing in any development task if the users didn’t have to add external dependencies like in Node.js 13 of the respondents believed that it would encourage them more for testing . 7 people were in a limbo and said maybe and the rest 3 out of the 23 respondents said no it wouldn’t matter to them.

37

Figure 35: Follow up question response for Deno’s browser support feature

Deno unlike Node.js follows the browser’s API meaning scripts written in JavaScript without Deno namespace and all the features supported by it works in all modern web browsers , upon asking their thoughts on this feature most of the respondents had a positive attitude towards this feature 10 people out of the 23 respondents believed this was a good feature ,11 people said it was okay that Deno supported browser’s API and the rest 3 said it was a bad feature.

Figure 36 : Follow up question response for third-party libraries in Deno

With the active Developer community almost all the most used third-party libraries have already started support for Deno too, upon asking if this would tempt the respondents to try Deno 47.8% (11 people) answered that it would interest them to try Deno. 30.4% (7 people)

38 expressed that it maybe tempts them to try Deno. The rest 21.7% (5 people) out of the 23 respondents said that this wouldn’t tempt them to give Deno a chance.

Figure 37: Follow up question response for Deno’s maturity for production

Few of the big companies have already started using Deno for their server-side JavaScript needs ,upon asking the opinion of the respondents if Deno is mature enough to be used for production , majority 60.9%(14 people) out of the 23 respondents expressed Deno is ready for production , the rest 39.1%(9 people) believed that it isn’t mature enough for production.

39

5 Evaluation

The results from the initial survey along with the follow-up survey were analysed and dis- cussed the results are further evaluated below along with my own experience and reflection on whole writing process for this paper. Further scope of the research and what improve- ments can be done further to this research are discussed below. And the conclusion is discussed in a new chapter.

5.1 Impression of Deno

Despite of Node.js being a go-to choice for JavaScript server-side development for a good amount of time. It was very interesting to see the prospects Deno had brought in after all these years. My expectation from the target group towards Deno was pretty positive from the get-go and after the survey was completed it was almost clear that individuals who participated on the survey were very impressed on the features and Deno and Deno as a new prospect for server-side development .

Most of the participants except a few individuals had already been working with JavaScript for few years in average expressed very positive attitude and concerns over Node.js and some people who had been working actively or had just only tried Deno considered Deno as a new rival to Node.js.

Even though there were less amount of respondents who filled up the survey from what I had imagined and the amount of work I put in to get to as much people as I could reach out to it was clear from the data that Deno presented some particular advantages over Node.js and the individuals who participated in the survey mostly appreciated them all including but not limited to first-class Typescript support out of the box, robust permissions system and import modules from URLs.

As most of the respondents were positive and expressed excitements towards the new runtime engine Deno there were a few scepticisms as well but that was expected consider- ing how long Node.js has been active and serving the purpose of server-side development with its well-established ecosystem for about a decade along with the massive active com- munity. As well as the large number of various literature and documentation on how to get started with Node.js also contributed for the code newbies to be more attracted to Node.js.

While comparing with my personal knowledge to the data gained from the survey it was quite surprising to see how the results were quite aligned with my expectations. The biggest

40 concern people presented was the people concern about security in Node.js , all the re- spondents had divided opinions over all the other features, but they were strongly im- pressed with the security feature of Deno , requiring of permission for access to hardware ,file and network was the most liked feature and has no negative attitude from the respond- ents.

5.2 For now, Node.js or Deno?

From the results gathered it seemed pretty clear that there are individuals that have worked with Node.js in average of 2 years so it is definitely a big change to people that have been working with Node.js but it was assuring from the results that Node.js isn’t leaving or fading away any time soon . Even though there’s so much new ideas and features to explore in Deno some individuals have had no experience whatsoever , some individuals heard about Deno from the survey itself, so It definitely hasn’t been on everybody’s knowledge of what it is and why is it different from Node.js .

From the data acquired I think it’s safe to say that people are sticking and maybe should stick to Node.js for the time being , despite saying that it was really interesting to see how many people wanted to try out Deno and expressed their frustrations and concern towards things like node_modules and especially security . I believe as people will get wary in the future what Deno has to offer comparing to Node.js people will be more inclined to it but for now it’s very clear that Node.js is still the prevalent runtime engine for server-side develop- ment with JavaScript.

5.3 Deno’s Future prospect

From the data acquired the future for Deno looked pretty solid ,even though some of the respondents were a bit reserved for trying something new , a good amount of respondents were very willing to give Deno a shot if not right away but definitely in future and I believe that once Deno starts to be adopted in future by some more big companies and once the Deno’s ecosystem starts being a bit more solid in terms of the third party module this num- ber I believe the numbers are always going to rise.

And the response from the individuals that had already used Deno was also mostly on the good side of the spectrum which only supports the growth of Deno in the future. One reason I think that is holding back Deno is it not being mature enough for production even though it was really impressive for me personally in the first project I had for Deno.

41

5.4 Validity of the results

As far as the validity of the data collected for this research goes all the responses received from the survey was creditable. No hampering or influencing the results was done. The theoretical data used in this paper are all from trusted sources , most of the theoretical data collected for the paper were either from the official websites or articles written by respected individuals in the community and the data for theoretical part which were from books were also from highly renowned sources.

One thing that needs to be mentioned again is because of the size of the respondents for the survey presented the paper has definitely affected the outcome of this paper and it doesn’t express the opinions of the whole software development community.

5.5 Reflection on the thesis process

Despite some minor hiccups while writing this research paper, I believe that the thesis pro- cess went smooth as I expected. I was provided with ample guidance from the teacher s as well as some of the respondents to the survey were also very active on helping me for making this research complete. Few minor changes were made to the initial plan of the research with the consultation of the thesis advisor.

Finding ample time to work in this research process while also keeping a part-time job was one of major factor for the research to go this long. One of the advantage I had because of me being a bit active on trying different things was that I already had a small server made with Deno as soon as it came out last year , so it gave me an insight of what I was putting myself into for the research. It also played huge role for me to choose this topic because personally I was very much impressed with the prospects of Deno.

Because of Deno being comparatively new compared to Node.js I had to rely heavily on online resources to write about it. There were very less literature present in the time of this research and all the literature focused more on the practical aspect of how to create a server for Deno. Finding literature for Node.js was much easier compared to that of Deno.

If I had bit more time and chance to do this research again, I would make sure that the initial idea of the research was thoroughly complete, I would have created a server for both Deno and Node.js and compared them. One other thing I would have done was find a way to get through to more individuals as a sample size for the survey, but personally I think Deno

42 being something new in respect to Node.js made people a bit hesitant to answer the survey questions.

All in all, I think this was a great experience for me to learn about Deno more in depth and see the technical side of Node.js more thoroughly than I had ever before. Learning some- thing new is always exciting and it definitely extended my knowledge base of JavaScript runtime engines.

5.6 Further research topics

I personally believe that there is so much extra stuff that can be added or followed up for this research. Like the initial plan of this research comparison of both runtime engines can be done by creating a simple REST server to test for the technical ability of both runtime engines considering performance and applicability. A separate research can be done show- casing Deno’s abilities and features because there are so many papers done in the same context for Node.js.

For further research there can be a practical comparison of performance like the one above in this research theoretical background that could be done with something extra like a hello world comparison but including third -party libraries of both Node.js and Deno and also further comparison could be done by creating simple API proxy .

As Deno gets more mature day by day and people more wary of its excellent features I think finding literature to write about it in a more detailed manner will be easy. With the possible growth of Deno in near future finding more respondents to increase the sample size of the survey might also lead to a different conclusion then the one I came up with if there was a follow up research in this topic.

43

6 Conclusions

This research was not done to advocate for either Node.js or Deno but to find out the opin- ions of the individuals that if they thought Deno will replace Node.js as the new way of writing server-side JavaScript.

What I can clearly conclude from this research is that Node.js is not going anywhere anytime soon, even though Deno has all those features that all the JavaScript server-side develop- ers were lacking and had been wanting all these years. I believe that the response made by the respondents for the survey even though the amount of responses were inadequate in my opinion, but it definitely shows a trend which is a good part of any research paper.

As the famous French proverb goes to each their own Deno and Node.js have their own contrast. The new and exciting features of Deno to the well-established ecosystem of Node.js. Even though Node.js is not going anywhere soon the attitude and concern of de- velopers towards the existing issues of Node.js like security and the risk of third-party mod- ules were very alarming which might lead the developers to opt out for Deno instead of Node.js in the near future.

While it seems that Node.js is still relevant to most of the developers Deno has a very good potential to be a rival and is already has some promising prospects ,what can be definitely concluded from this research is that even if Deno might or might not be able to replace Node.js which has been around for a good old decade now, it will definitely be used as an alternative to Node.js for JavaScript’s server-side needs. And who knows in a few years the situation and the needs of developers might bring on the change after all.

44

References

Bibliography

Arrachequesne, Damien. "Socket.IO." https://socket.io/index.html, accessed Jan 11, 2021.

Bartek Iwańczuk and Luca Casonato. "Deno 1.7 Release Notes." https://deno.land/posts/v1.7, accessed Feb 14, 2021.

Bartek Iwańczuk, Luca Casonato, and Ryan Dahl. "Deno - A secure runtime for JavaScript and TypeScript." https://deno.land/posts/v1.8, accessed Mar 11, 2021.

Bartek Iwańczuk, Luca Casonato, and Ryan Dahl. "Deno 1.5 Release Notes." https://deno.land/posts/v1.5, accessed Feb 13, 2021.

Bartek Iwańczuk, Ryan Dahl, and Luca Casonato. "Deno 1.4 Release Notes." https://deno.land/posts/v1.4, accessed Feb 13, 2021. blog.npmjs.org. "npm Blog Archive: kik, left-pad, and npm." https://blog.npmjs.org/post/141577284765/kik-left-pad-and-npm, accessed Jan 26, 2021.

Choubey Mayank. "Deno-vs-Node-Performance." https://github.com/mayank- choubey/Deno-vs-Node-Performance, accessed .

Cummings, Harry. 1. Why Node.js? - Learning Node.js for .NET Developers, 2016.

Dahl Ryan, Belder Bert, and Iwańczuk bartek. "Deno 1.0." https://deno.land/posts/v1, ac- cessed Jan 28, 2021. deno.land. "Deno - A secure runtime for JavaScript and TypeScript." https://deno.land/[email protected], accessed Mar 25, 2021. denocode.com. "DenoCode | Javascript & Typescript Server-side Code." https://deno- code.com, accessed Mar 16, 2021.

Doglio Fernando. Introducing Deno: A First Look at the Newest JavaScript Runtime: Apress, 2020.

Eich, Brendan. "Popularity – Brendan Eich." ( APR 3 , 2008). expressjs.com. "Express - Node.js web application framework." https://expressjs.com/, ac- cessed Jan 11, 2021.

Herron, David. Node Web Development. Olton, UNITED KINGDOM: Packt Publishing, Limited, 2013. krisk. "Deno - A secure runtime for JavaScript and TypeScript." https://deno.land/x/[email protected], accessed Mar 25, 2021.

Luca Casonato, Ryan Dahl, and Bartek Iwańczuk. "Deno 1.6 Release Notes." https://deno.land/posts/v1.6, accessed Feb 14, 2021.

45

McKeaveney Martin. "Deno: A Simple Guide." https://www.martinmck.com/posts/deno-a- simple-guide/, accessed Mar 21, 2021.

McLeod Dr.Saul. "What’s the difference between qualitative and quantitative research?" https://www.simplypsychology.org/qualitative-quantitative.html, accessed .

Nodejs.dev. "A brief history of Node.js." https://nodejs.dev/, accessed Dec 28, 2020.

Nodejs.org. "About Node.js." https://nodejs.org/en/about/, accessed Dec 28, 2020. npmjs.com. "npm Axios." https://www.npmjs.com/package/axios, accessed .

Reichen Tim. "Deno - A secure runtime for JavaScript and TypeScript." https://deno.land/x/[email protected], accessed Mar 22, 2021.

Rully Yulian, M. F. Building REST API Services using Deno and PostgreSQL: Native En- terprise, 2020. tutorialspoint.com. "Node.js - Event Loop - Tutorialspoint." https://www.tutori- alspoint.com/nodejs/nodejs_event_loop.htm#:~:text=Event%2DDriven%20Program- ming&text=js%20uses%20events%20heav- ily%20and,for%20the%20event%20to%20occur., accessed .

46

Appendices Figure 1 : Example of Non-blocking code in Node.js ...... 6 Figure 2: Event driven architecture in Node.js (tutorialspoint.com 2021) ...... 6 Figure 3: Example of a npm package axios in npm directory (npmjs.com 2020) ...... 8 Figure 4: Example of permission error in Deno ...... 10 Figure 5: A code snippet demonstrating top-level await in Deno ...... 10 Figure 6: Deno’s standard library from Deno’s official website (deno.land 2021)...... 11 Figure 7: Example of a simple test script in Deno (McKeaveney Martin 2020) ...... 12 Figure 8: Example of a third-party module called fuse in Deno's official Website (krisk 2020) ...... 13 Figure 9 : Hello world script in Deno(Choubey Mayank 2021) ...... 16 Figure 10: Hello world Script in Node.js (Choubey Mayank 2021) ...... 16 Figure 11: Performance comparison between Node.js and Deno with a single concurrent connection and with 1000 repetitions The more lower the number the better the performance (Choubey Mayank 2021) ...... 17 Figure 12: Details of every 10% quantiles of the test for performance comparison between Node.js and Deno with single concurrent connection. The lower the number the better the performance. (Choubey Mayank 2021) ...... 18 Figure 13:Performance comparison between Node.js and Deno with 10 concurrent connections and with 1000 repetitions .The more lower the number the better the performance. (Choubey Mayank 2021) ...... 19 Figure 14:Details of every 10% quantiles of the test for performance comparison between Node.js and Deno with 10 concurrent connection. The lower the number the better the performance. (Choubey Mayank 2021) ...... 19 Figure 15:Performance comparison between Node.js and Deno with 25 concurrent connections and with 1000 repetitions .The more lower the number the better the performance. (Choubey Mayank 2021) ...... 20 Figure 16: Details of every 10% quantiles of the test for performance comparison between Node.js and Deno with 25 concurrent connection. The lower the number the better the performance. (Choubey Mayank 2021) ...... 21 Figure 17: Response on question about current status...... 26 Figure 18: Response on experience with JavaScript ...... 27 Figure 19: Response on experience with server-side JavaScript ...... 27 Figure 20: Response for question about experience with Node.js ...... 28 Figure 21: Response for question about experience with Deno ...... 28 Figure 22 : Response for question about their knowledge on Deno ...... 29 Figure 23: Response for question about runtime engines ...... 30

47

Figure 24 : Response for question about experience TypeScript ...... 30 Figure 25 : Response for question about TypeScript support ...... 31 Figure 26 : Response for question about their opinion on their learning interest ...... 31 Figure 27 : Response for question about their experience with Deno compared to Node.js ...... 32 Figure 28 : Response for question about opinions over security ...... 32 Figure 29 : Response for question about opinions on node_modules ...... 33 Figure 30: Response for question about Deno’s top-level await feature ...... 34 Figure 31 : Response for question about permissions and security in Deno ...... 34 Figure 32: Response for question If Deno would replace Node.js ...... 35 Figure 33 : Follow up question response for Deno’s features ...... 36 Figure 34:Follow up question responses about testing in Deno ...... 37 Figure 35: Follow up question response for Deno’s browser support feature ...... 38 Figure 36 : Follow up question response for third-party libraries in Deno ...... 38 Figure 37: Follow up question response for Deno’s maturity for production ...... 39

48