官术网_书友最值得收藏!

Chapter 1. Object-oriented JavaScript

Ever since the early days of the Web, there has been a need for more dynamic and responsive interfaces. While it's OK to read static HTML pages of text and even better when they are beautifully presented with the help of CSS, it's much more fun to engage with applications in our browsers, such as e-mail, calendars, banking, shopping, drawing, playing games, and text editing. All that is possible thanks to JavaScript, the programming language of the Web. JavaScript started with simple one-liners embedded in HTML, but is now used in much more sophisticated ways. Developers leverage the object-oriented nature of the language to build scalable code architectures made up of reusable pieces.

If you look at the past and present buzzwords in web development—DHTML, Ajax, Web 2.0, HTML5—they all essentially mean HTML, CSS, and JavaScript. HTML for content, CSS for presentation, and JavaScript for behavior. In other words, JavaScript is the glue that makes everything work together so that we can build rich web applications.

But that's not all, JavaScript can be used for more than just the Web.

JavaScript programs run inside a host environment. The web browser is the most common environment, but it's not the only one. Using JavaScript, you can create all kinds of widgets, application extensions, and other pieces of software, as you'll see in a bit. Taking the time to learn JavaScript is a smart investment; you learn one language and can then write all kinds of different applications running on multiple platforms, including mobile and server-side applications. These days, it's safe to say that JavaScript is everywhere.

This book starts from zero, and does not assume any prior programming knowledge other than some basic understanding of HTML. Although there is one chapter dedicated to the web browser environment, the rest of the book is about JavaScript in general, so it's applicable to all environments.

Let's start with the following:

  • A brief introduction to the story behind JavaScript
  • The basic concepts you'll encounter in discussions on object-oriented programming
主站蜘蛛池模板: 四会市| 高安市| 出国| 政和县| 兰考县| 天台县| 淮滨县| 西畴县| 荣昌县| 建宁县| 门源| 泾源县| 永清县| 噶尔县| 惠水县| 大姚县| 益阳市| 宁安市| 安泽县| 内江市| 黄冈市| 望都县| 久治县| 宁化县| 会理县| 洪洞县| 五莲县| 蓝田县| 杭锦后旗| 麦盖提县| 淮北市| 平塘县| 井陉县| 达拉特旗| 招远市| 东乌| 绥中县| 五大连池市| 府谷县| 兴化市| 孙吴县|