وبلاگ بلیان

Programming in CoffeeScript (Developer's Library)

معرفی کتاب «Programming in CoffeeScript (Developer's Library)» نوشتهٔ Mark Bates در سال 2012. این کتاب در فرمت pdf، زبان انگلیسی ارائه شده است. «Programming in CoffeeScript (Developer's Library)» در دستهٔ بدون دسته‌بندی قرار دارد.

**Use CoffeeScript to Write Better JavaScript Code Than Ever Before!**If you can do it in JavaScript, you can do it better in CoffeeScript. And, since CoffeeScript “compiles down” to JavaScript, your code will fit neatly into virtually any web environment. In __Programming in CoffeeScript__, Mark Bates shows web developers why CoffeeScript is so useful and how it avoids the problems that often make JavaScript code buggy and unmanageable. He guides you through every feature and technique you need to write quality CoffeeScript code and shows how to take advantage of CoffeeScript’s increasingly robust toolset. Bates begins with the absolute basics of running and compiling CoffeeScript and then introduces syntax, control structures, functions, collections, and classes. Through same page code comparisons, you’ll discover exactly how CoffeeScript improves on JavaScript. Next, you’ll put it to work in building applications that are powerful, flexible, maintainable, concise, reliable, and secure. Bates shares valuable tips for better development, illuminating CoffeeScript’s hidden gems and warning you about its remaining “rough edges.” The book concludes with a start-to-finish application case study showing how to code back-ends and front-ends and integrate powerful frameworks and libraries. Coverage includes * Understanding the right ways to compile and execute CoffeeScript* Using CoffeeScript’s clean syntax to focus on your code, not JavaScript’s distractions* Working with CoffeeScript’s control structures, functions, and arguments* Taking full advantage of CoffeeScript’s implementation of collections and iterators* Leveraging CoffeeScript’s full class support to create complex data models* Automating common application development tasks with Cake and Cakefiles* Configuring Jasmine with CoffeeScript support, and using it to systematically test your code* Writing Node.js server-side applications in CoffeeScript* Using CoffeeScript to write jQuery and Backbone.js applications* Integrating framework code to avoid “reinventing the wheel” Want a better way to create the JavaScript code your web applications need? CoffeeScript is the solution–__and this book will help you master it__! Table of Contents 8 Dedication 6 Acknowledgments 13 About the Author 15 Preface 16 What Is CoffeeScript? 18 Who Is This Book For? 20 How to Read This Book 20 How This Book Is Organized 22 Part I: Core CoffeeScript 23 Part II: CoffeeScript in Practice 23 Installing CoffeeScript 24 How to Run the Examples 24 Notes 25 Part I: Core Coffeescript 26 1 Getting Started 28 The CoffeeScript REPL 28 In-Browser Compilation 31 Caveats 32 Command-Line Compilation 32 The CoffeeScript CLI 33 Wrapping Up 37 Notes 37 2 The Basics 38 Syntax 38 Scope and Variables 43 Interpolation 48 Extended Regular Expressions 56 Wrapping Up 57 Notes 57 3 Control Structures 58 Operators and Aliases 58 If/Unless 77 Switch/Case Statements 85 Wrapping Up 88 Notes 88 4 Functions and Arguments 90 Function Basics 93 Arguments 95 Default Arguments 97 Splats... 100 Wrapping Up 104 Notes 104 5 Collections and Iterations 106 Arrays 106 Ranges 115 Objects/Hashes 121 Loops and Iteration 130 Comprehensions 141 The do Keyword 144 Wrapping Up 145 Notes 146 6 Classes 148 Defining Classes 148 Defining Functions 150 The constructor Function 151 Scope in Classes 152 Extending Classes 162 Class-Level Functions 170 Prototype Functions 175 Binding (-> Versus =>) 176 Wrapping Up 183 Notes 183 Part II: CoffeeScript in Practice 184 7 Cake and Cakefiles 186 Getting Started 186 Creating Cake Tasks 187 Running Cake Tasks 188 Using Options 188 Invoking Other Tasks 192 Wrapping Up 194 Notes 195 8 Testing with Jasmine 196 Installing Jasmine 197 Setting Up Jasmine 197 Introduction to Jasmine 200 Unit Testing 201 Before and After 206 Custom Matchers 212 Wrapping Up 215 Notes 216 9 Intro to Node.js 218 What Is Node.js? 218 Installing Node 219 Getting Started 220 Streaming Responses 222 Building a CoffeeScript Server 224 Trying Out the Server 239 Wrapping Up 240 Notes 240 10 Example: Todo List Part 1 (Server-side) 242 Installing and Setting Up Express 243 Setting Up MongoDB Using Mongoose 247 Writing the Todo API 250 Querying with Mongoose 251 Wrapping Up 261 Notes 261 11 Example: Todo List Part 2 (Client-side w/ jQuery) 262 Priming the HTML with Twitter Bootstrap 262 Interacting with jQuery 265 Hooking Up the New Todo Form 267 Listing Existing Todos 272 Updating Todos 273 Deleting Todos 277 Wrapping Up 278 Notes 278 12 Example: Todo List Part 3 (Client-side w/ Backbone.js) 280 What Is Backbone.js? 280 Setting Up Backbone.js 281 Writing our Todo Model and Collection 285 Listing Todos Using a View 288 Creating New Todos 290 A View per Todo 293 Deleting Models from Views 298 Wrapping Up 300 Notes 300 Index 302 A 302 B 303 C 303 D 304 E 304 F 305 G-H 305 I 305 J-K 305 L 306 M-N 306 O 306 P 307 Q-R 307 S 307 T 307 U 308 V 308 W-X-Y-Z 308

Use CoffeeScript to Write Better JavaScript Code Than Ever Before!

If you can do it in JavaScript, you can do it better in CoffeeScript. And, since CoffeeScript 'compiles down' to JavaScript, your code will fit neatly into virtually any web environment. In Programming in CoffeeScript, Mark Bates shows web developers why CoffeeScript is so useful and how it avoids the problems that often make JavaScript code buggy and unmanageable. He guides you through every feature and technique you need to write quality CoffeeScript code and shows how to take advantage of CoffeeScript’s increasingly robust toolset.

Bates begins with the absolute basics of running and compiling CoffeeScript and then introduces syntax, control structures, functions, collections, and classes. Through same page code comparisons, you’ll discover exactly how CoffeeScript improves on JavaScript. Next, you’ll put it to work in building applications that are powerful, flexible, maintainable, concise, reliable, and secure. Bates shares valuable tips for better development, illuminating CoffeeScript’s hidden gems and warning you about its remaining 'rough edges.' The book concludes with a start-to-finish application case study showing how to code back-ends and front-ends and integrate powerful frameworks and libraries. Coverage includes

  • Understanding the right ways to compile and execute CoffeeScript
  • Using CoffeeScript’s clean syntax to focus on your code, not JavaScript’s distractions
  • Working with CoffeeScript’s control structures, functions, and arguments
  • Taking full advantage of CoffeeScript’s implementation of collections and iterators
  • Leveraging CoffeeScript’s full class support to create complex data models
  • Automating common application development tasks with Cake and Cakefiles
  • Configuring Jasmine with CoffeeScript support, and using it to systematically test your code
  • Writing Node.js server-side applications in CoffeeScript
  • Using CoffeeScript to write jQuery and Backbone.js applications
  • Integrating framework code to avoid 'reinventing the wheel'

Want a better way to create the JavaScript code your web applications need? CoffeeScript is the solution–and this book will help you master it!

Use CoffeeScript to Write Better JavaScript Code Than Ever Before! If you can do it in JavaScript, you can do it better in CoffeeScript. And, since CoffeeScript "compiles down" to JavaScript, your code will fit neatly into virtually any web environment. In Programming in CoffeeScript, Mark Bates shows web developers why CoffeeScript is so useful and how it avoids the problems that often make JavaScript code buggy and unmanageable. He guides you through every feature and technique you need to write quality CoffeeScript code and shows how to take advantage of CoffeeScript's increasingly robust toolset. Bates begins with the absolute basics of running and compiling CoffeeScript and then introduces syntax, control structures, functions, collections, and classes. Through same page code comparisons, you'll discover exactly how CoffeeScript improves on JavaScript. Next, you'll put it to work in building applications that are powerful, flexible, maintainable, concise, reliable, and secure. Bates shares valuable tips for better development, illuminating CoffeeScript's hidden gems and warning you about its remaining "rough edges." The book concludes with a start-to-finish application case study showing how to code back-ends and front-ends and integrate powerful frameworks and libraries. Coverage includes Understanding the right ways to compile and execute CoffeeScript Using CoffeeScript's clean syntax to focus on your code, not JavaScript's distractions Working with CoffeeScript's control structures, functions, and arguments Taking full advantage of CoffeeScript's implementation of collections and iterators Leveraging CoffeeScript's full class support to create complex data models Automating common application development tasks with Cake and Cakefiles Configuring Jasmine with CoffeeScript support, and using it to systematically test your code Writing Node.js server-side applications in CoffeeScript Using CoffeeScript to write jQuery and Backbone.js applications Integrating framework code to avoid "reinventing the wheel" Want a better way to create the JavaScript code your web applications need? CoffeeScript is the solution- and this book will help you master it! Use CoffeeScript to Write Better JavaScript Code Than Ever Before! If you can do it in JavaScript, you can do it better in CoffeeScript. And, since CoffeeScript compiles down to JavaScript, your code will fit neatly into virtually any web environment. In Programming in CoffeeScript , Mark Bates shows web developers why CoffeeScript is so useful and how it avoids the problems that often make JavaScript code buggy and unmanageable. He guides you through every feature and technique you need to write quality CoffeeScript code and shows how to take advantage of CoffeeScripts increasingly robust toolset. Bates begins with the absolute basics of running and compiling CoffeeScript and then introduces syntax, control structures, functions, collections, and classes. Through same page code comparisons, youll discover exactly how CoffeeScript improves on JavaScript. Next, youll put it to work in building applications that are powerful, flexible, maintainable, concise, reliable, and secure. Bates shares valuable tips for better development, illuminating CoffeeScripts hidden gems and warning you about its remaining rough edges. The book concludes with a start-to-finish application case study showing how to code back-ends and front-ends and integrate powerful frameworks and libraries. Coverage includes Want a better way to create the JavaScript code your web applications need? CoffeeScript is the solution and this book will help you master it !
دانلود کتاب Programming in CoffeeScript (Developer's Library)