万本电子书0元读

万本电子书0元读

顶部广告

Node.js Blueprints电子书

售       价:¥

6人正在读 | 0人评论 9.8

作       者:Krasimir Tsonev

出  版  社:Packt Publishing

出版时间:2014-06-16

字       数:121.2万

所属分类: 进口书 > 外文原版书 > 电脑/网络

温馨提示:数字商品不支持退换货,不提供源文件,不支持导出打印

为你推荐

  • 读书简介
  • 目录
  • 累计评论(0条)
  • 读书简介
  • 目录
  • 累计评论(0条)
A straightforward, practical guide containing step-by-step tutorials that will push your Node.js programming skills to the next level. If you are a web developer with experience in writing client-side JavaScript and want to discover the fascinating world of Node.js to develop fast and efficient web and desktop applications, then this book is for you.
目录展开

Node.js Blueprints

Table of Contents

Node.js Blueprints

Credits

About the Author

About the Reviewers

www.PacktPub.com

Support files, eBooks, discount offers, and more

Why subscribe?

Free access for Packt account holders

Preface

What this book covers

What you need for this book

Who this book is for

Conventions

Reader feedback

Customer support

Downloading the example code

Downloading the color images of this book

Errata

Piracy

Questions

1. Common Programming Paradigms

Node.js fundamentals

Organizing your code logic in modules

Building a car construction application

Using the car's engine

Understanding inter-module communication

Asynchronous programming

Exploring middleware architecture

Composition versus inheritance

Managing dependencies

Summary

2. Developing a Basic Site with Node.js and Express

Getting acquainted with Express

Installing Express

Using package.json

Using a command-line tool

Managing routes

Handling dynamic URLs and the HTML forms

Returning a response

The example-logging system

Summary

3. Writing a Blog Application with Node.js and AngularJS

Exploring AngularJS

Bootstrapping AngularJS applications

Using directives and controllers

Data binding

Encapsulating logic with modules

Preparing data with filters

Dependency injection

The model in the context of AngularJS

Final words on AngularJS

Selecting and initializing the database

Using NoSQL with MongoDB

Using MySQL

Developing the client side with Angular

Implementing a control panel

Summary

4. Developing a Chat with Socket.IO

Exploring WebSockets and Socket.IO

Understanding the basic application structure

Running the server

Adding Socket.IO

Writing the client side of the chat

Preparing the HTML markup

Writing the chat logic

Implementing user-to-user communication

Changing the server-side code

Making changes to the frontend of the chat

Summary

5. Creating a To-do Application with Backbone.js

Exploring the Backbone.js framework

Recognizing the framework dependency

Extending the functionality

Understanding Backbone.js as an event-driven framework

Using models

Using collections

Implementing views

Using the router

Talking to the backend

Writing the backend of the application

Running the Node.js server

Managing the to-do lists

Writing the frontend

Looking into the base of the application

Listing the to-do activities

Adding, deleting, and editing the to-do lists

Summary

6. Using Node.js as a Command-line Tool

Exploring the required modules

Planning the application

Obtaining images from a folder

Authorizing the Flickr protocol

Obtaining your application's Key and Secret

Writing into the Flickr.js module

Running our application tool

Uploading the images

Summary

7. Showing a Social Feed with Ember.js

Preparing the application

Running the server and delivering the assets

Getting tweets based on a user handle

Discovering Ember.js

Knowing the dependencies of Ember.js

Understanding Ember.js

Exploring classes and objects in Ember.js

Computed properties

Router

Views and templates

Models

Controllers

Writing Ember.js

Defining the templates

Defining the routes

Handling the user input and moving to the second screen

Displaying the tweets

Summary

8. Developing Web App Workflow with Grunt and Gulp

Introducing the task runners

Exploring Grunt

Concatenating files

Minifying your code

Watching files for changes

Ignoring files

Creating our own task

Generating a cache manifest file

Documenting our code

Discovering Gulp

Installing Gulp and fetching plugins

Concatenating and minifying with Gulp

Creating your own Gulp plugin

Summary

9. Automate Your Testing with Node.js

Understanding the importance of writing tests

Choosing a testing methodology

Test-driven development

Behavior-driven development

Classifying tests

Using Jasmine

Installing Jasmine

Defining the module for testing

Following the test-driven development concept

Testing the file-reading process

Finding strings in the file content

Writing an integration test

Testing with Mocha

Installation

Translating our example using Mocha

Selecting a reporter

Testing with a headless browser

Writing the subject of our test

Testing with PhantomJS

Developing the micro testing framework

Understanding how PhantomJS works

Writing the actual test

Testing with DalekJS

Summary

10. Writing Flexible and Modular CSS

Writing modular CSS

BEM (block, element, modifier)

Using the Object Oriented CSS approach

Separate structure and skin

Separate container and content

Scalable and modular architecture for CSS

Atomic design

Exploring CSS preprocessors

Using Less

Defining variables

Using mixins

Structuring the styles into nested definitions

Using Sass

Using Stylus

Working with AbsurdJS

Styling a simple login form

Summary

11. Writing a REST API

Discovering REST and API

Developing an online library – a REST API

Defining the API parts

Writing the base

Implementing the API router

Writing the responder

Working with the database

Creating a new record

Editing a record

Deleting a record

Displaying all the books

Adding a default route

Testing the API

Summary

12. Developing Desktop Apps with Node.js

Using node-webkit

Writing the base of the application

Writing the package.json file

Preparing the HTML layout

Designing the JavaScript base

Displaying and using the working directory

Displaying the current working directory

Showing the files and folders

Changing the current directory

Copying, moving, and deleting files

Extending the application

Tweaking the updateFileArea function

Loading a new page for the selected image

Showing the image and its dimensions

Removing the toolbar

Summary

Index

累计评论(0条) 0个书友正在讨论这本书 发表评论

发表评论

发表评论,分享你的想法吧!

买过这本书的人还买过

读了这本书的人还在读

回顶部