SlideShare a Scribd company logo
Introduction of Deno 1.0
By : Vishal Sharma (Node Js developer)
Deno is a new runtime for JavaScript and TypeScript .
Developed by Ryan Dahl - the creator of Node.js.
Since 2018, the creator of Node.js has been working on a new
JavaScript runtime called Deno that addresses some of the pain
points he had identified. Deno’s features include:
1. An improved security model
2. Decentralized package management
3. A standard library
4. Built in tooling
Deno 1.0 was just released. What better time to dive in? In this
post we’ll get started with Deno by building a small project.
What is Deno ?
Why we use Deno instead of Node
Deno aims to fix Node.js design mistakes and offers a new modern
development environment.
Deno is a new platform for writing applications using JavaScript and
TypeScript. Both platforms share the same philosophy – event-
driven architecture and asynchronous non-blocking tools to build
web servers and services. The author of Deno is Ryan Dahl, original
creator of Node.js. In 2018, he gave the famous talk “10 Things I
Regret About Node.js“ and announced his new project – Deno.
Deno aims to fix Node.js design mistakes and offers a new modern
development environment.
Both platforms serve the same purpose, but use different
mechanisms. Deno uses ES Modules as the default module system,
whereas Node.js uses CommonJS. External dependencies are loaded
using URLs, similar to browsers.
What are its main features?
Security (permissions)
Among the most important of Deno’s features is its focus on security.
As opposed to Node, Deno by default executes the code in a sandbox, which means that
runtime has no access to:
1. The file system
2. The network
3. Execution of other scripts
4. The environment variables
Let’s take a look at how the permission system works.
(async () => {
const encoder = new TextEncoder();
const data = encoder.encode('Hello worldn');
await Deno.writeFile('hello.txt', data);
await Deno.writeFile('hello2.txt', data);
})();
When we run it by executing:
deno run write-hello.ts
Modules
Deno, just like browsers, loads modules by URLs. Many people got confused at first when they saw an
import statement with a URL on the server side, but it actually makes sense — just bear with me:
import { assertEquals } from "https://deno.land/std/testing/asserts.ts";
What’s the big deal with importing packages by their URLs, you may ask? The answer is simple: by
using URLs, Deno packages can be distributed without a centralized registry such as npm, which
recently has had a lot of problems, all of them explained
By importing code via URL, we make it possible for package creators to host their code wherever they
see fit — decentralization at its finest.
No more package.json and node_modules.
Do I have to import it by the URL all the time?
Constantly typing URLs would be very tedious. Thankfully, Deno presents us with two options to avoid
doing that.
The first option is to re-export the imported module from a local file, like so:
export { test, assertEquals } from "https://deno.land/std/testing/mod.ts";
Let’s say the file above is called local-test-utils.ts. Now, if we want to again make use of
either test or assertEquals functions, we can just reference it like this:
import { test, assertEquals } from './local-test-utils.ts';So it doesn’t really matter if it’s loaded from a
URL or not
Browser compatibility
Deno aims to be browser-compatible. Technically speaking, when using the ES modules,
we don’t have to use any build tools like webpack to make our application ready to use in a
browser.
However, tools like Babel will transpile the code to the ES5 version of JavaScript, and as a
result, the code can be run even in older browsers that don’t support all the newest
features of the language. But that also comes at the price of including a lot of unnecessary
code in the final file and bloating the output file.
It is up to us to decide what our main goal is and choose accordingly.
TypeScript support out of the box
Deno makes it easy to use TypeScript without the need for any config files. Still, it is
possible to write programs in plain JavaScript and execute them with Deno without any
trouble.
Summary
Deno, the new runtime for TypeScript and JavaScript, is an interesting project that
has been steadily growing for quite some time now. But it still has a long way to go
before it’s considered production-ready.
With it’s decentralized approach, it takes the necessary step of freeing the
JavaScript ecosystem from the centralized package registry that is npm.
Dahl says that he expects to release version 1.0 by the end of the summer, so if you
are interested in Deno’s future developments, star its repository.
Reference :
https://blog.logrocket.com/what-is-deno/
https://www.twilio.com/blog/getting-started-deno
Ad

More Related Content

What's hot (20)

Node.js - Introduction and role in Frontend Development
Node.js - Introduction and role in Frontend DevelopmentNode.js - Introduction and role in Frontend Development
Node.js - Introduction and role in Frontend Development
Julián David Duque
 
Introduction to NPM and building CLI Tools with Node.js
Introduction to NPM and building CLI Tools with Node.jsIntroduction to NPM and building CLI Tools with Node.js
Introduction to NPM and building CLI Tools with Node.js
Suroor Wijdan
 
Best node js course
Best node js courseBest node js course
Best node js course
bestonlinecoursescoupon
 
Node JS Crash Course
Node JS Crash CourseNode JS Crash Course
Node JS Crash Course
Haim Michael
 
Nodejs
NodejsNodejs
Nodejs
Prem Sanil
 
Getting Started With PowerShell Scripting
Getting Started With PowerShell ScriptingGetting Started With PowerShell Scripting
Getting Started With PowerShell Scripting
Ravikanth Chaganti
 
Ceph Day Beijing: Ceph-Dokan: A Native Windows Ceph Client
Ceph Day Beijing: Ceph-Dokan: A Native Windows Ceph Client Ceph Day Beijing: Ceph-Dokan: A Native Windows Ceph Client
Ceph Day Beijing: Ceph-Dokan: A Native Windows Ceph Client
Ceph Community
 
Node js
Node jsNode js
Node js
Fatih Şimşek
 
Node js - Enterprise Class
Node js - Enterprise ClassNode js - Enterprise Class
Node js - Enterprise Class
Glenn Block
 
Generating Visual Studio Code Extensions for Xtext DSLs
Generating Visual Studio Code Extensions for Xtext DSLsGenerating Visual Studio Code Extensions for Xtext DSLs
Generating Visual Studio Code Extensions for Xtext DSLs
Karsten Thoms
 
NodeJS guide for beginners
NodeJS guide for beginnersNodeJS guide for beginners
NodeJS guide for beginners
Enoch Joshua
 
The Ring programming language version 1.2 book - Part 7 of 84
The Ring programming language version 1.2 book - Part 7 of 84The Ring programming language version 1.2 book - Part 7 of 84
The Ring programming language version 1.2 book - Part 7 of 84
Mahmoud Samir Fayed
 
I Just Want to Run My Code: Waypoint, Nomad, and Other Things
I Just Want to Run My Code: Waypoint, Nomad, and Other ThingsI Just Want to Run My Code: Waypoint, Nomad, and Other Things
I Just Want to Run My Code: Waypoint, Nomad, and Other Things
Michael Lange
 
Build a chatroom!
Build a chatroom!Build a chatroom!
Build a chatroom!
SheilaJimenezMorejon
 
Introduction to NodeJS
Introduction to NodeJSIntroduction to NodeJS
Introduction to NodeJS
Cere Labs Pvt. Ltd
 
Nodejs vatsal shah
Nodejs vatsal shahNodejs vatsal shah
Nodejs vatsal shah
Vatsal N Shah
 
Nodejs basics
Nodejs basicsNodejs basics
Nodejs basics
monikadeshmane
 
Introduction to Node js
Introduction to Node jsIntroduction to Node js
Introduction to Node js
Pragnesh Vaghela
 
Meteor Introduction
Meteor IntroductionMeteor Introduction
Meteor Introduction
Randell Hynes
 
Install Project INK
Install Project INKInstall Project INK
Install Project INK
IshanJoshi36
 
Node.js - Introduction and role in Frontend Development
Node.js - Introduction and role in Frontend DevelopmentNode.js - Introduction and role in Frontend Development
Node.js - Introduction and role in Frontend Development
Julián David Duque
 
Introduction to NPM and building CLI Tools with Node.js
Introduction to NPM and building CLI Tools with Node.jsIntroduction to NPM and building CLI Tools with Node.js
Introduction to NPM and building CLI Tools with Node.js
Suroor Wijdan
 
Node JS Crash Course
Node JS Crash CourseNode JS Crash Course
Node JS Crash Course
Haim Michael
 
Getting Started With PowerShell Scripting
Getting Started With PowerShell ScriptingGetting Started With PowerShell Scripting
Getting Started With PowerShell Scripting
Ravikanth Chaganti
 
Ceph Day Beijing: Ceph-Dokan: A Native Windows Ceph Client
Ceph Day Beijing: Ceph-Dokan: A Native Windows Ceph Client Ceph Day Beijing: Ceph-Dokan: A Native Windows Ceph Client
Ceph Day Beijing: Ceph-Dokan: A Native Windows Ceph Client
Ceph Community
 
Node js - Enterprise Class
Node js - Enterprise ClassNode js - Enterprise Class
Node js - Enterprise Class
Glenn Block
 
Generating Visual Studio Code Extensions for Xtext DSLs
Generating Visual Studio Code Extensions for Xtext DSLsGenerating Visual Studio Code Extensions for Xtext DSLs
Generating Visual Studio Code Extensions for Xtext DSLs
Karsten Thoms
 
NodeJS guide for beginners
NodeJS guide for beginnersNodeJS guide for beginners
NodeJS guide for beginners
Enoch Joshua
 
The Ring programming language version 1.2 book - Part 7 of 84
The Ring programming language version 1.2 book - Part 7 of 84The Ring programming language version 1.2 book - Part 7 of 84
The Ring programming language version 1.2 book - Part 7 of 84
Mahmoud Samir Fayed
 
I Just Want to Run My Code: Waypoint, Nomad, and Other Things
I Just Want to Run My Code: Waypoint, Nomad, and Other ThingsI Just Want to Run My Code: Waypoint, Nomad, and Other Things
I Just Want to Run My Code: Waypoint, Nomad, and Other Things
Michael Lange
 
Install Project INK
Install Project INKInstall Project INK
Install Project INK
IshanJoshi36
 

Similar to Introduction of deno 1 (20)

Deno vs Node.js: A Comprehensive Comparison.docx
Deno vs Node.js: A Comprehensive Comparison.docxDeno vs Node.js: A Comprehensive Comparison.docx
Deno vs Node.js: A Comprehensive Comparison.docx
Vignesh Nethaji
 
Nodejs
NodejsNodejs
Nodejs
dssprakash
 
JS Fest 2019. Ryan Dahl. Deno, a new way to JavaScript
JS Fest 2019. Ryan Dahl. Deno, a new way to JavaScriptJS Fest 2019. Ryan Dahl. Deno, a new way to JavaScript
JS Fest 2019. Ryan Dahl. Deno, a new way to JavaScript
JSFestUA
 
Node J pdf.docx
Node J pdf.docxNode J pdf.docx
Node J pdf.docx
PSK Technolgies Pvt. Ltd. IT Company Nagpur
 
Node J pdf.docx
Node J pdf.docxNode J pdf.docx
Node J pdf.docx
PSK Technolgies Pvt. Ltd. IT Company Nagpur
 
Node.js Web Development .pdf
Node.js Web Development .pdfNode.js Web Development .pdf
Node.js Web Development .pdf
Abanti Aazmin
 
unit 2 of Full stack web development subject
unit 2 of Full stack web development subjectunit 2 of Full stack web development subject
unit 2 of Full stack web development subject
JeneferAlan1
 
Unity Loves HelNode - Helsinki Node.js November Meetup
Unity Loves HelNode - Helsinki Node.js November MeetupUnity Loves HelNode - Helsinki Node.js November Meetup
Unity Loves HelNode - Helsinki Node.js November Meetup
Helsinki Node.js Meetup Group
 
Shipping NodeJS with Docker and CoreOS
Shipping NodeJS with Docker and CoreOSShipping NodeJS with Docker and CoreOS
Shipping NodeJS with Docker and CoreOS
Ross Kukulinski
 
8 good reasons to learn docker
8 good reasons to learn docker8 good reasons to learn docker
8 good reasons to learn docker
prabhasathya
 
GettingStartedWithDocker_docker
GettingStartedWithDocker_dockerGettingStartedWithDocker_docker
GettingStartedWithDocker_docker
Hasibul Haque
 
DockerDay2015: Keynote
DockerDay2015: KeynoteDockerDay2015: Keynote
DockerDay2015: Keynote
Docker-Hanoi
 
node_js.pptx
node_js.pptxnode_js.pptx
node_js.pptx
dipen55
 
Node Js Non-blocking or asynchronous Blocking or synchronous.pdf
Node Js Non-blocking or asynchronous  Blocking or synchronous.pdfNode Js Non-blocking or asynchronous  Blocking or synchronous.pdf
Node Js Non-blocking or asynchronous Blocking or synchronous.pdf
DarshanaMallick
 
The world of Docker and Kubernetes
The world of Docker and Kubernetes The world of Docker and Kubernetes
The world of Docker and Kubernetes
vty
 
Node.js and .NET Core.pdf
Node.js and .NET Core.pdfNode.js and .NET Core.pdf
Node.js and .NET Core.pdf
Appdeveloper10
 
Steps to Install NPM and Node.js on Windows and MAC
Steps to Install NPM and Node.js on Windows and MACSteps to Install NPM and Node.js on Windows and MAC
Steps to Install NPM and Node.js on Windows and MAC
Inexture Solutions
 
.Net Core
.Net Core.Net Core
.Net Core
Bohdan Pashkovskyi
 
Netbeans
NetbeansNetbeans
Netbeans
ZulquaNaaz
 
Node.js and the MEAN Stack Building Full-Stack Web Applications.pdf
Node.js and the MEAN Stack Building Full-Stack Web Applications.pdfNode.js and the MEAN Stack Building Full-Stack Web Applications.pdf
Node.js and the MEAN Stack Building Full-Stack Web Applications.pdf
lubnayasminsebl
 
Deno vs Node.js: A Comprehensive Comparison.docx
Deno vs Node.js: A Comprehensive Comparison.docxDeno vs Node.js: A Comprehensive Comparison.docx
Deno vs Node.js: A Comprehensive Comparison.docx
Vignesh Nethaji
 
JS Fest 2019. Ryan Dahl. Deno, a new way to JavaScript
JS Fest 2019. Ryan Dahl. Deno, a new way to JavaScriptJS Fest 2019. Ryan Dahl. Deno, a new way to JavaScript
JS Fest 2019. Ryan Dahl. Deno, a new way to JavaScript
JSFestUA
 
Node.js Web Development .pdf
Node.js Web Development .pdfNode.js Web Development .pdf
Node.js Web Development .pdf
Abanti Aazmin
 
unit 2 of Full stack web development subject
unit 2 of Full stack web development subjectunit 2 of Full stack web development subject
unit 2 of Full stack web development subject
JeneferAlan1
 
Unity Loves HelNode - Helsinki Node.js November Meetup
Unity Loves HelNode - Helsinki Node.js November MeetupUnity Loves HelNode - Helsinki Node.js November Meetup
Unity Loves HelNode - Helsinki Node.js November Meetup
Helsinki Node.js Meetup Group
 
Shipping NodeJS with Docker and CoreOS
Shipping NodeJS with Docker and CoreOSShipping NodeJS with Docker and CoreOS
Shipping NodeJS with Docker and CoreOS
Ross Kukulinski
 
8 good reasons to learn docker
8 good reasons to learn docker8 good reasons to learn docker
8 good reasons to learn docker
prabhasathya
 
GettingStartedWithDocker_docker
GettingStartedWithDocker_dockerGettingStartedWithDocker_docker
GettingStartedWithDocker_docker
Hasibul Haque
 
DockerDay2015: Keynote
DockerDay2015: KeynoteDockerDay2015: Keynote
DockerDay2015: Keynote
Docker-Hanoi
 
node_js.pptx
node_js.pptxnode_js.pptx
node_js.pptx
dipen55
 
Node Js Non-blocking or asynchronous Blocking or synchronous.pdf
Node Js Non-blocking or asynchronous  Blocking or synchronous.pdfNode Js Non-blocking or asynchronous  Blocking or synchronous.pdf
Node Js Non-blocking or asynchronous Blocking or synchronous.pdf
DarshanaMallick
 
The world of Docker and Kubernetes
The world of Docker and Kubernetes The world of Docker and Kubernetes
The world of Docker and Kubernetes
vty
 
Node.js and .NET Core.pdf
Node.js and .NET Core.pdfNode.js and .NET Core.pdf
Node.js and .NET Core.pdf
Appdeveloper10
 
Steps to Install NPM and Node.js on Windows and MAC
Steps to Install NPM and Node.js on Windows and MACSteps to Install NPM and Node.js on Windows and MAC
Steps to Install NPM and Node.js on Windows and MAC
Inexture Solutions
 
Node.js and the MEAN Stack Building Full-Stack Web Applications.pdf
Node.js and the MEAN Stack Building Full-Stack Web Applications.pdfNode.js and the MEAN Stack Building Full-Stack Web Applications.pdf
Node.js and the MEAN Stack Building Full-Stack Web Applications.pdf
lubnayasminsebl
 
Ad

Recently uploaded (20)

ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes
 
Role of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered ManufacturingRole of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered Manufacturing
Andrew Leo
 
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc
 
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In France
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In FranceManifest Pre-Seed Update | A Humanoid OEM Deeptech In France
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In France
chb3
 
What is Model Context Protocol(MCP) - The new technology for communication bw...
What is Model Context Protocol(MCP) - The new technology for communication bw...What is Model Context Protocol(MCP) - The new technology for communication bw...
What is Model Context Protocol(MCP) - The new technology for communication bw...
Vishnu Singh Chundawat
 
tecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdftecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdf
fjgm517
 
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul
 
Greenhouse_Monitoring_Presentation.pptx.
Greenhouse_Monitoring_Presentation.pptx.Greenhouse_Monitoring_Presentation.pptx.
Greenhouse_Monitoring_Presentation.pptx.
hpbmnnxrvb
 
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Impelsys Inc.
 
Cyber Awareness overview for 2025 month of security
Cyber Awareness overview for 2025 month of securityCyber Awareness overview for 2025 month of security
Cyber Awareness overview for 2025 month of security
riccardosl1
 
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Aqusag Technologies
 
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-UmgebungenHCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
panagenda
 
Generative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in BusinessGenerative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in Business
Dr. Tathagat Varma
 
2025-05-Q4-2024-Investor-Presentation.pptx
2025-05-Q4-2024-Investor-Presentation.pptx2025-05-Q4-2024-Investor-Presentation.pptx
2025-05-Q4-2024-Investor-Presentation.pptx
Samuele Fogagnolo
 
Semantic Cultivators : The Critical Future Role to Enable AI
Semantic Cultivators : The Critical Future Role to Enable AISemantic Cultivators : The Critical Future Role to Enable AI
Semantic Cultivators : The Critical Future Role to Enable AI
artmondano
 
Drupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy ConsumptionDrupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy Consumption
Exove
 
Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025
Splunk
 
Linux Professional Institute LPIC-1 Exam.pdf
Linux Professional Institute LPIC-1 Exam.pdfLinux Professional Institute LPIC-1 Exam.pdf
Linux Professional Institute LPIC-1 Exam.pdf
RHCSA Guru
 
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptxDevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
Justin Reock
 
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdfComplete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Software Company
 
ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes Partner Innovation Updates for May 2025
ThousandEyes
 
Role of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered ManufacturingRole of Data Annotation Services in AI-Powered Manufacturing
Role of Data Annotation Services in AI-Powered Manufacturing
Andrew Leo
 
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc Webinar: Consumer Expectations vs Corporate Realities on Data Broker...
TrustArc
 
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In France
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In FranceManifest Pre-Seed Update | A Humanoid OEM Deeptech In France
Manifest Pre-Seed Update | A Humanoid OEM Deeptech In France
chb3
 
What is Model Context Protocol(MCP) - The new technology for communication bw...
What is Model Context Protocol(MCP) - The new technology for communication bw...What is Model Context Protocol(MCP) - The new technology for communication bw...
What is Model Context Protocol(MCP) - The new technology for communication bw...
Vishnu Singh Chundawat
 
tecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdftecnologias de las primeras civilizaciones.pdf
tecnologias de las primeras civilizaciones.pdf
fjgm517
 
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul Shares 5 Steps to Implement AI Agents for Maximum Business Efficien...
Noah Loul
 
Greenhouse_Monitoring_Presentation.pptx.
Greenhouse_Monitoring_Presentation.pptx.Greenhouse_Monitoring_Presentation.pptx.
Greenhouse_Monitoring_Presentation.pptx.
hpbmnnxrvb
 
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Enhancing ICU Intelligence: How Our Functional Testing Enabled a Healthcare I...
Impelsys Inc.
 
Cyber Awareness overview for 2025 month of security
Cyber Awareness overview for 2025 month of securityCyber Awareness overview for 2025 month of security
Cyber Awareness overview for 2025 month of security
riccardosl1
 
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Massive Power Outage Hits Spain, Portugal, and France: Causes, Impact, and On...
Aqusag Technologies
 
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-UmgebungenHCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
HCL Nomad Web – Best Practices und Verwaltung von Multiuser-Umgebungen
panagenda
 
Generative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in BusinessGenerative Artificial Intelligence (GenAI) in Business
Generative Artificial Intelligence (GenAI) in Business
Dr. Tathagat Varma
 
2025-05-Q4-2024-Investor-Presentation.pptx
2025-05-Q4-2024-Investor-Presentation.pptx2025-05-Q4-2024-Investor-Presentation.pptx
2025-05-Q4-2024-Investor-Presentation.pptx
Samuele Fogagnolo
 
Semantic Cultivators : The Critical Future Role to Enable AI
Semantic Cultivators : The Critical Future Role to Enable AISemantic Cultivators : The Critical Future Role to Enable AI
Semantic Cultivators : The Critical Future Role to Enable AI
artmondano
 
Drupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy ConsumptionDrupalcamp Finland – Measuring Front-end Energy Consumption
Drupalcamp Finland – Measuring Front-end Energy Consumption
Exove
 
Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025Splunk Security Update | Public Sector Summit Germany 2025
Splunk Security Update | Public Sector Summit Germany 2025
Splunk
 
Linux Professional Institute LPIC-1 Exam.pdf
Linux Professional Institute LPIC-1 Exam.pdfLinux Professional Institute LPIC-1 Exam.pdf
Linux Professional Institute LPIC-1 Exam.pdf
RHCSA Guru
 
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptxDevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
DevOpsDays Atlanta 2025 - Building 10x Development Organizations.pptx
Justin Reock
 
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdfComplete Guide to Advanced Logistics Management Software in Riyadh.pdf
Complete Guide to Advanced Logistics Management Software in Riyadh.pdf
Software Company
 
Ad

Introduction of deno 1

  • 1. Introduction of Deno 1.0 By : Vishal Sharma (Node Js developer)
  • 2. Deno is a new runtime for JavaScript and TypeScript . Developed by Ryan Dahl - the creator of Node.js. Since 2018, the creator of Node.js has been working on a new JavaScript runtime called Deno that addresses some of the pain points he had identified. Deno’s features include: 1. An improved security model 2. Decentralized package management 3. A standard library 4. Built in tooling Deno 1.0 was just released. What better time to dive in? In this post we’ll get started with Deno by building a small project. What is Deno ?
  • 3. Why we use Deno instead of Node Deno aims to fix Node.js design mistakes and offers a new modern development environment. Deno is a new platform for writing applications using JavaScript and TypeScript. Both platforms share the same philosophy – event- driven architecture and asynchronous non-blocking tools to build web servers and services. The author of Deno is Ryan Dahl, original creator of Node.js. In 2018, he gave the famous talk “10 Things I Regret About Node.js“ and announced his new project – Deno. Deno aims to fix Node.js design mistakes and offers a new modern development environment. Both platforms serve the same purpose, but use different mechanisms. Deno uses ES Modules as the default module system, whereas Node.js uses CommonJS. External dependencies are loaded using URLs, similar to browsers.
  • 4. What are its main features? Security (permissions) Among the most important of Deno’s features is its focus on security. As opposed to Node, Deno by default executes the code in a sandbox, which means that runtime has no access to: 1. The file system 2. The network 3. Execution of other scripts 4. The environment variables Let’s take a look at how the permission system works. (async () => { const encoder = new TextEncoder(); const data = encoder.encode('Hello worldn'); await Deno.writeFile('hello.txt', data); await Deno.writeFile('hello2.txt', data); })(); When we run it by executing: deno run write-hello.ts
  • 5. Modules Deno, just like browsers, loads modules by URLs. Many people got confused at first when they saw an import statement with a URL on the server side, but it actually makes sense — just bear with me: import { assertEquals } from "https://deno.land/std/testing/asserts.ts"; What’s the big deal with importing packages by their URLs, you may ask? The answer is simple: by using URLs, Deno packages can be distributed without a centralized registry such as npm, which recently has had a lot of problems, all of them explained By importing code via URL, we make it possible for package creators to host their code wherever they see fit — decentralization at its finest. No more package.json and node_modules. Do I have to import it by the URL all the time? Constantly typing URLs would be very tedious. Thankfully, Deno presents us with two options to avoid doing that. The first option is to re-export the imported module from a local file, like so: export { test, assertEquals } from "https://deno.land/std/testing/mod.ts"; Let’s say the file above is called local-test-utils.ts. Now, if we want to again make use of either test or assertEquals functions, we can just reference it like this: import { test, assertEquals } from './local-test-utils.ts';So it doesn’t really matter if it’s loaded from a URL or not
  • 6. Browser compatibility Deno aims to be browser-compatible. Technically speaking, when using the ES modules, we don’t have to use any build tools like webpack to make our application ready to use in a browser. However, tools like Babel will transpile the code to the ES5 version of JavaScript, and as a result, the code can be run even in older browsers that don’t support all the newest features of the language. But that also comes at the price of including a lot of unnecessary code in the final file and bloating the output file. It is up to us to decide what our main goal is and choose accordingly. TypeScript support out of the box Deno makes it easy to use TypeScript without the need for any config files. Still, it is possible to write programs in plain JavaScript and execute them with Deno without any trouble.
  • 7. Summary Deno, the new runtime for TypeScript and JavaScript, is an interesting project that has been steadily growing for quite some time now. But it still has a long way to go before it’s considered production-ready. With it’s decentralized approach, it takes the necessary step of freeing the JavaScript ecosystem from the centralized package registry that is npm. Dahl says that he expects to release version 1.0 by the end of the summer, so if you are interested in Deno’s future developments, star its repository. Reference : https://blog.logrocket.com/what-is-deno/ https://www.twilio.com/blog/getting-started-deno