Download JavaScript

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Audience response wikipedia , lookup

Web 2.0 wikipedia , lookup

Web analytics wikipedia , lookup

Transcript
JavaScript
William Hosbein
L1k3 th3 c00l l00k1ng d3s1gn?
JavaScript: Early Days
• 1995. Netscape Navigator incorporated Java into its browser.
• Enter Brendan Eich. Netscape hired Eich and gave him the
task to make Navigator’s Java support more accessible to nonJava programmers/developers.
• Eich decided that a loosely-typed scripting language would
suit the audience and environment.
• His target audience was a few thousand web designers and
developers who needed to use page elements, such as forms,
frames, or images, without a compiler or knowledge of OOP.
wHY n07 7RY 4 H0l1D4y 1N 1R3l4nD 7H1z y34R?
JavaScript: Early Problems
• Initially called “LiveScript,” JavaScript was soon renamed in an
apparent marketing mistake. This caused much confusion for
developers because both names were being tossed around in
the development community.
• By intention, JavaScript was very simple. This did create a
problem though.
• The fact that there was no compiler and that copying &
pasting code from/to web pages was very easy caused many
to view JavaScript as a toy.
• JavaScript also lacked an IDE and a reliable cross-platform
debugger. This, combined with a few security flaws and
several books aimed at non-programmers, caused many to
view it as “simple,” completely overshadowing its potential.
533 t3h 9r33n k0un7ri51D3
JavaScript: Early Successes?
• Amongst its problems, JavaScript did gain popularity.
• Although not its main intention, the biggest use of JavaScript,
early on, was controlling images and document contents.
• Surprisingly, the main use of JavaScript was the switching of
images in response to mouse events.
• Navigator’s implementation of JavaScript – which allowed for
this image swapping – was something that IE lacked.
• Developers actually started to only check for Navigator in their
scripts, ignoring IE as a lost cause.
• Ignoring IE all together for developing created another bump in
the road for a true cross-platform standards-driven Web.
7h3 w0nd3rful pu85
JavaScript: Moving On
• Issues during the browser wars affected a standards-driven
Web. Thus, compatibility problems with JavaScript were
rampant from browser to browser.
• It was decided that JavaScript be handed over to an
international standards body called the ECMA to take the
development away from competing browser developers.
• JavaScript was even officially renamed to ECMAScript or
ECMA-262, but it’s still widely referred to as JavaScript.
4nD m4ny 1n73R3571n' M491C4L cr347ur3z
JavaScript: Now
• JavaScript’s dependence on context-specific object models is
both the strength and weakness in its implementation.
• Unlike other languages, JavaScript’s capabilities can’t be
extended or overridden by developers. This leaves them
dependent on the unpredictable software vendors.
• Despite these drawbacks, JavaScript is the most popular and
widely used language on the net.
l1K3 73H L177L3 l3Pr3Ch4un5
JavaScript: Cons
• Inability to hide source
• Example: Obstacle for developers who wish to protect their code
as intellectual property.
• Lack of an IDE, debugger, and other development tools
• Example: Some WYSISYG development tools with excellent crossbrowser libraries have been hurt by Mozilla’s abandonment of the
old Netscape document.layers object model.
4 l3pr3Ch4uN 0nC3 4774Ck3D My s1ST3R...
JavaScript: Pros
• Features from Perl:
• associative arrays
• loosely typed variables
• regular expressions
• Features from C/C++ and Java:
• clean, block-parsed syntax, objects and classes
• highly evolved date, math, and string libraries
N0 r3411Y! 5h3 W42 PICkIN9 cL0V3R2 wi7H 4 5p4d3 9iV3N
H3r 8Y 7yl3R - H3r 80yFri3nD - 4 pud9Y ph00784Ll3R 4ND
5in9Er 0F M4Ny 50N95: "73h 83LLy 0f a Ph0078alL3r",
"73H 5h032 0f P0W3R", "H0W 70 rUN ph457"...
The End!!!
Well, of the history part, you’re not rid of me yet