SlideShare una empresa de Scribd logo
1 de 38
Descargar para leer sin conexión
About JavaScript Libraries
Too many choices
eventually leads to

ambiguity and blurring
use case boundaries.
Often one library is
compared with other.

Comparing a jQuery library
with Backbone or Angular is
JavaScript libraries
work at different level
of abstraction.

meaningless. It is like

comparing a processor with
motherboard. You can
compare two processors or
two motherboards but not
both…
So exactly, how does

different libraries and
tools fit into front-end
stack?
Web Application
Widget (UI)
toolkits

Build tools
Full stack
frameworks
Package
managers

Web app
libraries
(MV*)

Graphics
libraries

Base / DOM libraries

Core JavaScript

Web browser

Module
loaders
Web Application
Widget (UI)
toolkits

Build tools
Full stack
frameworks
Package
managers

Web app
libraries
(MV*)

Graphics
libraries

Module
loaders

Base / DOM libraries

Core JavaScript

Web browser

JavaScript

engine provided
by the browser
Core JavaScript engine
• Every browser vendor provides

JavaScript engine
• Varying degree of JavaScript support
by engines
• Sometimes some APIs are buggy or
incomplete

• Major engines are Chakra, V8,
SpiderMonkey, Nitro, Carakan, etc.
Web Application
Widget (UI)
toolkits

Build tools
Full stack
frameworks
Package
managers

Web app
libraries
(MV*)

Graphics
libraries

Base / DOM libraries

Module
loaders

Hide browser
differences &
provide
consistent cross

Core JavaScript

Web browser

browser API.
Base/DOM manipulation libraries
• Provide abstraction over Core JavaScript
APIs and functions
• Mask browser differences to a larger
extent
• Ideal for basic operations like DOM, CSS,
events, animations & Ajax manipulation
• Provide little help for code organization

Few popular libraries are:
Web Application
Widget (UI)
toolkits

Build tools
Full stack
frameworks
Package
managers

Web app
libraries
(MV*)

Graphics
libraries

Base / DOM libraries

Core JavaScript

Web browser

Module
loaders
UI/Widget libraries(toolkits)
• Provide out of box reusable UI
widgets/components for rapidly building

web applications
• Some libraries provide features for
building desktop user experience
• Often called toolkits rather than libraries
as utility part is often miniature as
compared to component part

Few popular libraries are:
Web Application
Widget (UI)
toolkits

Build tools
Full stack
frameworks
Package
managers

Web app
libraries
(MV*)

Graphics
libraries

Base / DOM libraries

Core JavaScript

Web browser

Module
loaders
Web application libraries (MV*)
• Provide features for writing maintainable
& organized JavaScript code
• Client heavy applications usually suffer
from code maintenance as JavaScript
leaves modularization to programmers
• Few libraries heavily influence the design
of application while other libraries leave
design decisions to developers.

Few popular libraries are:
Web Application
Widget (UI)
toolkits

Build tools
Full stack
frameworks
Package
managers

Web app
libraries
(MV*)

Graphics
libraries

Base / DOM libraries

Core JavaScript

Web browser

Module
loaders
Graphics libraries
• Provide abstraction over raw Canvas, SVG
and WebGL APIs
• Used for online games, image editors and
data visualization
• Object oriented libraries but by no means
substitute for building web applications.
Do not even compare with web application
libraries

Few popular libraries are:
Web Application
Widget (UI)
toolkits

Build tools
Full stack
frameworks
Package
managers

Web app
libraries
(MV*)

Graphics
libraries

Base / DOM libraries

Core JavaScript

Web browser

Module
loaders
JavaScript module loaders
• Library dependencies and JavaScript code
gets very nasty as code base increases
• Module loaders provide solution to
address code dependency issues
• Loaders works seamlessly with modern
MV* libraries where everything is
organized as modules or components

Few popular libraries are:
Web Application
Widget (UI)
toolkits

Build tools
Full stack
frameworks
Package
managers

Web app
libraries
(MV*)

Graphics
libraries

Base / DOM libraries

Core JavaScript

Web browser

Module
loaders
JavaScript package managers
• Not really part of web application but part
of project development ecosystem
• Provide tools to install, upgrade, configure
& remove resources used by the project
• It also supports dependency management
and versioning

Few popular managers are:
Web Application
Widget (UI)
toolkits

Build tools
Full stack
frameworks
Package
managers

Web app
libraries
(MV*)

Graphics
libraries

Base / DOM libraries

Core JavaScript

Web browser

Module
loaders
JavaScript build tools
• What Ant and Maven to Java is what build
tools to JavaScript
• Build tools automates various JavaScript
tasks like concatenating, minifying, JSHint
files and other resources. Also automates
Unit testing of code.
• They are not directly used by web
application but external to application just
like package managers.

Few popular tools are:
Web Application
Widget (UI)
toolkits

Build tools
Full stack
frameworks
Package
managers

Web app
libraries
(MV*)

Graphics
libraries

Base / DOM libraries

Core JavaScript

Web browser

Module
loaders
Full stack frameworks
• There are some that are more than simple
libraries or toolkits. Thus they are

frameworks
• They provide support for many front-end
tasks
• There is no such thing as perfect
framework that can cater to every type of
need

Few popular frameworks are:
Closer look at
other JavaScript

libraries
JavaScript polyfills
• Polyfills is basically a JavaScript code that
emulates standard API that is lacking in

some older browsers
• Some polyfills also try to fix broken API in
the web browsers
• There are polyfills for almost every
HTML5 feature and number is quite large

Modernizr is not a JavaScript polyfill. It is
very small library that detect native
implementation of new features. In
Progressive Enhancement technique,
developer tests for certain feature using
Modernizr and if absent loads the required
polyfill conditionally.
Functional programming
• Along with object oriented nature,
JavaScript also has rich heritage of

functional programming
• In certain cases, functional programming is
much more natural than OOP
• Functional reactive programming uses
functional programming as its basic
building block

Few popular reactive & functional
libraries are:
Unit testing libraries
• Almost half of the JavaScript code is never
unit tested by developers as JavaScript is

still considered as scripting only language
• In Test Driven Development (TDD), tests
are written before any functional code
• As TDD and client heavy application gets
more popular, need for unit testing of
JavaScript code will be ever higher

Few popular unit testing libraries are:
So how do you

choose the right
library?
Some libraries are natural fit

Principle of
Natural fit

for certain tasks. For

example, Backbone.js is
apparent choice for RESTful
JSON applications.

Frameworks like Angular,
Backbone, etc. are good
choice for building single
page applications.
Depending upon the
requirements, it makes sense
to use full stack solutions

Full stack
heavy
libraries

that also direct application
design; while in other cases
lightweight solutions are
much better where
architectural design is left
entirely to developers.

Bare minimum
lightweight
libraries
Especially in case of rapid
prototyping, it helps

development teams to select
libraries with less learning
curve & easier adaptation.

Library like knockout or
Kendo UI is easier to catch on
for WPF or Silverlight
developers as their
philosophy is based on same
MVVM pattern.

T
eam
adaptability &

learning curve
But these are just guidelines
and one should not treat
them like lines carved in
stone. They are meant to be
bent as required.
But before you do anything with JavaScript libraries, do yourself a favor by asking this
question that will save you from many troubles in future

Do you really need a third-party library?
Should you build your custom library?
1.

Libraries create code lock-ins. Not
possible to replace easily

2.

Future can never be anticipated
when choosing a certain library.
Sometimes libraries are forced to

solve the problems they were not
intended to solve in the beginning;
resulting in bloated code base
3.

Many library version upgrades are
not backward compatible. APIs
break easily

Some problems with

third-party libraries
4.

Abstractions provided by libraries
make developers ignore

performance issues
5.

For non-expert developers who
are not aware of JavaScript &

browser internals use library APIs
in not so optimal way.
6.

Writing clean, efficient &
maintainable code is the
responsibility of developers. In the
end, libraries are blamed for any
performance issues.

Some problems with

third-party libraries
In the end, the only
conclusion is choose wisely
Author:
Harshal Patil
@softHarsh
http://definitelysimple.com
http://www.linkedin.com/in/hapatil

Más contenido relacionado

La actualidad más candente

NetBeans Platform for Rich Client Development
NetBeans Platform for Rich Client DevelopmentNetBeans Platform for Rich Client Development
NetBeans Platform for Rich Client DevelopmentWidura Wijenayake
 
Anatomy of an HTML 5 mobile web app
Anatomy of an HTML 5 mobile web app Anatomy of an HTML 5 mobile web app
Anatomy of an HTML 5 mobile web app Ivano Malavolta
 
Store
StoreStore
StoreESUG
 
DrupalCamp Ghent 2014 - Developing Drupal 7 with Drupal 8 in mind
DrupalCamp Ghent 2014 - Developing Drupal 7 with Drupal 8 in mindDrupalCamp Ghent 2014 - Developing Drupal 7 with Drupal 8 in mind
DrupalCamp Ghent 2014 - Developing Drupal 7 with Drupal 8 in mindJoeri van Dooren
 
Programming is Fun with ASP.NET MVC
Programming is Fun with ASP.NET MVCProgramming is Fun with ASP.NET MVC
Programming is Fun with ASP.NET MVCIan Carnaghan
 
Making Multisite Work for You
Making Multisite Work for YouMaking Multisite Work for You
Making Multisite Work for Youdrywallbmb
 
PHP Frameworks Review - Mar 19 2015
PHP Frameworks Review - Mar 19 2015PHP Frameworks Review - Mar 19 2015
PHP Frameworks Review - Mar 19 2015kyphpug
 
Silverlight difference faqs-1
Silverlight  difference faqs-1Silverlight  difference faqs-1
Silverlight difference faqs-1Umar Ali
 
Content Management Systems and Refactoring - Drupal, WordPress and eZ Publish
Content Management Systems and Refactoring - Drupal, WordPress and eZ PublishContent Management Systems and Refactoring - Drupal, WordPress and eZ Publish
Content Management Systems and Refactoring - Drupal, WordPress and eZ PublishJani Tarvainen
 
RIA Platform Comparison
RIA Platform ComparisonRIA Platform Comparison
RIA Platform ComparisonOliver Steele
 
Workshop HTML5+PhoneGap by Ivano Malavolta
Workshop HTML5+PhoneGap by Ivano Malavolta Workshop HTML5+PhoneGap by Ivano Malavolta
Workshop HTML5+PhoneGap by Ivano Malavolta Commit University
 
Web development in JavaEE7 with JSF, does it still matter?
Web development in JavaEE7 with JSF, does it still matter?Web development in JavaEE7 with JSF, does it still matter?
Web development in JavaEE7 with JSF, does it still matter?Paris Apostolopoulos
 
Em presentation victor herman
Em presentation victor hermanEm presentation victor herman
Em presentation victor hermanVictor Herman
 

La actualidad más candente (20)

NetBeans Platform for Rich Client Development
NetBeans Platform for Rich Client DevelopmentNetBeans Platform for Rich Client Development
NetBeans Platform for Rich Client Development
 
Anatomy of an HTML 5 mobile web app
Anatomy of an HTML 5 mobile web app Anatomy of an HTML 5 mobile web app
Anatomy of an HTML 5 mobile web app
 
Store
StoreStore
Store
 
DrupalCamp Ghent 2014 - Developing Drupal 7 with Drupal 8 in mind
DrupalCamp Ghent 2014 - Developing Drupal 7 with Drupal 8 in mindDrupalCamp Ghent 2014 - Developing Drupal 7 with Drupal 8 in mind
DrupalCamp Ghent 2014 - Developing Drupal 7 with Drupal 8 in mind
 
Top 10 Javascript Frameworks For Easy Web Development
Top 10 Javascript Frameworks For Easy Web DevelopmentTop 10 Javascript Frameworks For Easy Web Development
Top 10 Javascript Frameworks For Easy Web Development
 
Programming is Fun with ASP.NET MVC
Programming is Fun with ASP.NET MVCProgramming is Fun with ASP.NET MVC
Programming is Fun with ASP.NET MVC
 
Netbeans+platform+maven
Netbeans+platform+mavenNetbeans+platform+maven
Netbeans+platform+maven
 
Making Multisite Work for You
Making Multisite Work for YouMaking Multisite Work for You
Making Multisite Work for You
 
PHP Frameworks Review - Mar 19 2015
PHP Frameworks Review - Mar 19 2015PHP Frameworks Review - Mar 19 2015
PHP Frameworks Review - Mar 19 2015
 
Silverlight difference faqs-1
Silverlight  difference faqs-1Silverlight  difference faqs-1
Silverlight difference faqs-1
 
Content Management Systems and Refactoring - Drupal, WordPress and eZ Publish
Content Management Systems and Refactoring - Drupal, WordPress and eZ PublishContent Management Systems and Refactoring - Drupal, WordPress and eZ Publish
Content Management Systems and Refactoring - Drupal, WordPress and eZ Publish
 
Module 4 - Dreamweaver Templates (Static vs. Dynamic Content)
Module 4 - Dreamweaver Templates (Static vs. Dynamic Content)Module 4 - Dreamweaver Templates (Static vs. Dynamic Content)
Module 4 - Dreamweaver Templates (Static vs. Dynamic Content)
 
RIA Platform Comparison
RIA Platform ComparisonRIA Platform Comparison
RIA Platform Comparison
 
Workshop HTML5+PhoneGap by Ivano Malavolta
Workshop HTML5+PhoneGap by Ivano Malavolta Workshop HTML5+PhoneGap by Ivano Malavolta
Workshop HTML5+PhoneGap by Ivano Malavolta
 
Spring Mvc
Spring MvcSpring Mvc
Spring Mvc
 
Different Concepts on Databases
Different Concepts on DatabasesDifferent Concepts on Databases
Different Concepts on Databases
 
Practical HTML5
Practical HTML5Practical HTML5
Practical HTML5
 
Java
JavaJava
Java
 
Web development in JavaEE7 with JSF, does it still matter?
Web development in JavaEE7 with JSF, does it still matter?Web development in JavaEE7 with JSF, does it still matter?
Web development in JavaEE7 with JSF, does it still matter?
 
Em presentation victor herman
Em presentation victor hermanEm presentation victor herman
Em presentation victor herman
 

Similar a About javascript libraries

Introduction to backbone_js
Introduction to backbone_jsIntroduction to backbone_js
Introduction to backbone_jsMohammed Saqib
 
Intro to SPA using JavaScript & ASP.NET
Intro to SPA using JavaScript & ASP.NETIntro to SPA using JavaScript & ASP.NET
Intro to SPA using JavaScript & ASP.NETAlan Hecht
 
Single page application and Framework
Single page application and FrameworkSingle page application and Framework
Single page application and FrameworkChandrasekar G
 
Lessons learned from building Eclipse-based add-ons for commercial modeling t...
Lessons learned from building Eclipse-based add-ons for commercial modeling t...Lessons learned from building Eclipse-based add-ons for commercial modeling t...
Lessons learned from building Eclipse-based add-ons for commercial modeling t...IncQuery Labs
 
javaScriptLibrariesFrameworks.pptx
javaScriptLibrariesFrameworks.pptxjavaScriptLibrariesFrameworks.pptx
javaScriptLibrariesFrameworks.pptxMattMarino13
 
Isomorphic JavaScript with Node, WebPack, and React
Isomorphic JavaScript with Node, WebPack, and ReactIsomorphic JavaScript with Node, WebPack, and React
Isomorphic JavaScript with Node, WebPack, and ReactTyler Peterson
 
9 Best JavaScript Frameworks To Choose
9 Best JavaScript Frameworks To Choose9 Best JavaScript Frameworks To Choose
9 Best JavaScript Frameworks To ChooseAlbiorix Technology
 
Frontend War: Angular vs React vs Vue
Frontend War: Angular vs React vs VueFrontend War: Angular vs React vs Vue
Frontend War: Angular vs React vs VueMarudi Subakti
 
Presentation 1 Web--dev
Presentation 1 Web--devPresentation 1 Web--dev
Presentation 1 Web--devaltsav
 
Learning Single page Application chapter 1
Learning Single page Application chapter 1Learning Single page Application chapter 1
Learning Single page Application chapter 1Puguh Rismadi
 
Selecting the Best Javascript Web Framework
Selecting the Best Javascript Web FrameworkSelecting the Best Javascript Web Framework
Selecting the Best Javascript Web FrameworkRajitha Pathiraja
 
A sneak peek into the similarities and differences between java and java script
A sneak peek into the similarities and differences between java and java scriptA sneak peek into the similarities and differences between java and java script
A sneak peek into the similarities and differences between java and java scriptAMC Square
 
What is Mean Stack Development ?
What is Mean Stack Development ?What is Mean Stack Development ?
What is Mean Stack Development ?Balajihope
 
Frameworks Galore: A Pragmatic Review
Frameworks Galore: A Pragmatic ReviewFrameworks Galore: A Pragmatic Review
Frameworks Galore: A Pragmatic Reviewnetc2012
 
Isomorphic JavaScript – future of the web
Isomorphic JavaScript – future of the webIsomorphic JavaScript – future of the web
Isomorphic JavaScript – future of the webSigma Software
 

Similar a About javascript libraries (20)

Introduction to backbone_js
Introduction to backbone_jsIntroduction to backbone_js
Introduction to backbone_js
 
Intro to SPA using JavaScript & ASP.NET
Intro to SPA using JavaScript & ASP.NETIntro to SPA using JavaScript & ASP.NET
Intro to SPA using JavaScript & ASP.NET
 
Javascript frameworks
Javascript frameworksJavascript frameworks
Javascript frameworks
 
Single page application and Framework
Single page application and FrameworkSingle page application and Framework
Single page application and Framework
 
Lessons learned from building Eclipse-based add-ons for commercial modeling t...
Lessons learned from building Eclipse-based add-ons for commercial modeling t...Lessons learned from building Eclipse-based add-ons for commercial modeling t...
Lessons learned from building Eclipse-based add-ons for commercial modeling t...
 
javaScriptLibrariesFrameworks.pptx
javaScriptLibrariesFrameworks.pptxjavaScriptLibrariesFrameworks.pptx
javaScriptLibrariesFrameworks.pptx
 
Isomorphic JavaScript with Node, WebPack, and React
Isomorphic JavaScript with Node, WebPack, and ReactIsomorphic JavaScript with Node, WebPack, and React
Isomorphic JavaScript with Node, WebPack, and React
 
9 Best JavaScript Frameworks To Choose
9 Best JavaScript Frameworks To Choose9 Best JavaScript Frameworks To Choose
9 Best JavaScript Frameworks To Choose
 
Frontend War: Angular vs React vs Vue
Frontend War: Angular vs React vs VueFrontend War: Angular vs React vs Vue
Frontend War: Angular vs React vs Vue
 
Top java script frameworks ppt
Top java script frameworks pptTop java script frameworks ppt
Top java script frameworks ppt
 
Presentation 1 Web--dev
Presentation 1 Web--devPresentation 1 Web--dev
Presentation 1 Web--dev
 
Learning Single page Application chapter 1
Learning Single page Application chapter 1Learning Single page Application chapter 1
Learning Single page Application chapter 1
 
Selecting the Best Javascript Web Framework
Selecting the Best Javascript Web FrameworkSelecting the Best Javascript Web Framework
Selecting the Best Javascript Web Framework
 
A sneak peek into the similarities and differences between java and java script
A sneak peek into the similarities and differences between java and java scriptA sneak peek into the similarities and differences between java and java script
A sneak peek into the similarities and differences between java and java script
 
What is Mean Stack Development ?
What is Mean Stack Development ?What is Mean Stack Development ?
What is Mean Stack Development ?
 
Javascript libraries
Javascript librariesJavascript libraries
Javascript libraries
 
Introduction to Spring & Spring BootFramework
Introduction to Spring  & Spring BootFrameworkIntroduction to Spring  & Spring BootFramework
Introduction to Spring & Spring BootFramework
 
Frameworks Galore: A Pragmatic Review
Frameworks Galore: A Pragmatic ReviewFrameworks Galore: A Pragmatic Review
Frameworks Galore: A Pragmatic Review
 
Isomorphic JavaScript – future of the web
Isomorphic JavaScript – future of the webIsomorphic JavaScript – future of the web
Isomorphic JavaScript – future of the web
 
Frontend as a first class citizen
Frontend as a first class citizenFrontend as a first class citizen
Frontend as a first class citizen
 

Último

🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationMichael W. Hawkins
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptxHampshireHUG
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking MenDelhi Call girls
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)wesley chun
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdfhans926745
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEarley Information Science
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024Rafal Los
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Igalia
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 

Último (20)

🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptxEIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
EIS-Webinar-Prompt-Knowledge-Eng-2024-04-08.pptx
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024The 7 Things I Know About Cyber Security After 25 Years | April 2024
The 7 Things I Know About Cyber Security After 25 Years | April 2024
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 

About javascript libraries

  • 2.
  • 3. Too many choices eventually leads to ambiguity and blurring use case boundaries.
  • 4. Often one library is compared with other. Comparing a jQuery library with Backbone or Angular is JavaScript libraries work at different level of abstraction. meaningless. It is like comparing a processor with motherboard. You can compare two processors or two motherboards but not both…
  • 5. So exactly, how does different libraries and tools fit into front-end stack?
  • 6. Web Application Widget (UI) toolkits Build tools Full stack frameworks Package managers Web app libraries (MV*) Graphics libraries Base / DOM libraries Core JavaScript Web browser Module loaders
  • 7. Web Application Widget (UI) toolkits Build tools Full stack frameworks Package managers Web app libraries (MV*) Graphics libraries Module loaders Base / DOM libraries Core JavaScript Web browser JavaScript engine provided by the browser
  • 8. Core JavaScript engine • Every browser vendor provides JavaScript engine • Varying degree of JavaScript support by engines • Sometimes some APIs are buggy or incomplete • Major engines are Chakra, V8, SpiderMonkey, Nitro, Carakan, etc.
  • 9. Web Application Widget (UI) toolkits Build tools Full stack frameworks Package managers Web app libraries (MV*) Graphics libraries Base / DOM libraries Module loaders Hide browser differences & provide consistent cross Core JavaScript Web browser browser API.
  • 10. Base/DOM manipulation libraries • Provide abstraction over Core JavaScript APIs and functions • Mask browser differences to a larger extent • Ideal for basic operations like DOM, CSS, events, animations & Ajax manipulation • Provide little help for code organization Few popular libraries are:
  • 11. Web Application Widget (UI) toolkits Build tools Full stack frameworks Package managers Web app libraries (MV*) Graphics libraries Base / DOM libraries Core JavaScript Web browser Module loaders
  • 12. UI/Widget libraries(toolkits) • Provide out of box reusable UI widgets/components for rapidly building web applications • Some libraries provide features for building desktop user experience • Often called toolkits rather than libraries as utility part is often miniature as compared to component part Few popular libraries are:
  • 13. Web Application Widget (UI) toolkits Build tools Full stack frameworks Package managers Web app libraries (MV*) Graphics libraries Base / DOM libraries Core JavaScript Web browser Module loaders
  • 14. Web application libraries (MV*) • Provide features for writing maintainable & organized JavaScript code • Client heavy applications usually suffer from code maintenance as JavaScript leaves modularization to programmers • Few libraries heavily influence the design of application while other libraries leave design decisions to developers. Few popular libraries are:
  • 15. Web Application Widget (UI) toolkits Build tools Full stack frameworks Package managers Web app libraries (MV*) Graphics libraries Base / DOM libraries Core JavaScript Web browser Module loaders
  • 16. Graphics libraries • Provide abstraction over raw Canvas, SVG and WebGL APIs • Used for online games, image editors and data visualization • Object oriented libraries but by no means substitute for building web applications. Do not even compare with web application libraries Few popular libraries are:
  • 17. Web Application Widget (UI) toolkits Build tools Full stack frameworks Package managers Web app libraries (MV*) Graphics libraries Base / DOM libraries Core JavaScript Web browser Module loaders
  • 18. JavaScript module loaders • Library dependencies and JavaScript code gets very nasty as code base increases • Module loaders provide solution to address code dependency issues • Loaders works seamlessly with modern MV* libraries where everything is organized as modules or components Few popular libraries are:
  • 19. Web Application Widget (UI) toolkits Build tools Full stack frameworks Package managers Web app libraries (MV*) Graphics libraries Base / DOM libraries Core JavaScript Web browser Module loaders
  • 20. JavaScript package managers • Not really part of web application but part of project development ecosystem • Provide tools to install, upgrade, configure & remove resources used by the project • It also supports dependency management and versioning Few popular managers are:
  • 21. Web Application Widget (UI) toolkits Build tools Full stack frameworks Package managers Web app libraries (MV*) Graphics libraries Base / DOM libraries Core JavaScript Web browser Module loaders
  • 22. JavaScript build tools • What Ant and Maven to Java is what build tools to JavaScript • Build tools automates various JavaScript tasks like concatenating, minifying, JSHint files and other resources. Also automates Unit testing of code. • They are not directly used by web application but external to application just like package managers. Few popular tools are:
  • 23. Web Application Widget (UI) toolkits Build tools Full stack frameworks Package managers Web app libraries (MV*) Graphics libraries Base / DOM libraries Core JavaScript Web browser Module loaders
  • 24. Full stack frameworks • There are some that are more than simple libraries or toolkits. Thus they are frameworks • They provide support for many front-end tasks • There is no such thing as perfect framework that can cater to every type of need Few popular frameworks are:
  • 25. Closer look at other JavaScript libraries
  • 26. JavaScript polyfills • Polyfills is basically a JavaScript code that emulates standard API that is lacking in some older browsers • Some polyfills also try to fix broken API in the web browsers • There are polyfills for almost every HTML5 feature and number is quite large Modernizr is not a JavaScript polyfill. It is very small library that detect native implementation of new features. In Progressive Enhancement technique, developer tests for certain feature using Modernizr and if absent loads the required polyfill conditionally.
  • 27. Functional programming • Along with object oriented nature, JavaScript also has rich heritage of functional programming • In certain cases, functional programming is much more natural than OOP • Functional reactive programming uses functional programming as its basic building block Few popular reactive & functional libraries are:
  • 28. Unit testing libraries • Almost half of the JavaScript code is never unit tested by developers as JavaScript is still considered as scripting only language • In Test Driven Development (TDD), tests are written before any functional code • As TDD and client heavy application gets more popular, need for unit testing of JavaScript code will be ever higher Few popular unit testing libraries are:
  • 29. So how do you choose the right library?
  • 30. Some libraries are natural fit Principle of Natural fit for certain tasks. For example, Backbone.js is apparent choice for RESTful JSON applications. Frameworks like Angular, Backbone, etc. are good choice for building single page applications.
  • 31. Depending upon the requirements, it makes sense to use full stack solutions Full stack heavy libraries that also direct application design; while in other cases lightweight solutions are much better where architectural design is left entirely to developers. Bare minimum lightweight libraries
  • 32. Especially in case of rapid prototyping, it helps development teams to select libraries with less learning curve & easier adaptation. Library like knockout or Kendo UI is easier to catch on for WPF or Silverlight developers as their philosophy is based on same MVVM pattern. T eam adaptability & learning curve
  • 33. But these are just guidelines and one should not treat them like lines carved in stone. They are meant to be bent as required.
  • 34. But before you do anything with JavaScript libraries, do yourself a favor by asking this question that will save you from many troubles in future Do you really need a third-party library? Should you build your custom library?
  • 35. 1. Libraries create code lock-ins. Not possible to replace easily 2. Future can never be anticipated when choosing a certain library. Sometimes libraries are forced to solve the problems they were not intended to solve in the beginning; resulting in bloated code base 3. Many library version upgrades are not backward compatible. APIs break easily Some problems with third-party libraries
  • 36. 4. Abstractions provided by libraries make developers ignore performance issues 5. For non-expert developers who are not aware of JavaScript & browser internals use library APIs in not so optimal way. 6. Writing clean, efficient & maintainable code is the responsibility of developers. In the end, libraries are blamed for any performance issues. Some problems with third-party libraries
  • 37. In the end, the only conclusion is choose wisely