- Node.js Design Patterns(Second Edition)
- Mario Casciaro Luciano Mammino
- 235字
- 2021-07-14 11:01:22
Conventions
In this book, you will find a number of text styles that distinguish between different kinds of information. Here are some examples of these styles and an explanation of their meaning.
Code words in text, database table names, folder names, filenames, file extensions, pathnames, dummy URLs, user input, and Twitter handles are shown as follows: "ES2015 introduces the let
keyword to declare variables that respect the block scope."
A block of code is set as follows:
const zmq = require('zmq') const sink = zmq.socket('pull'); sink.bindSync("tcp://*:5001"); sink.on('message', buffer => { console.log(`Message from worker: ${buffer.toString()}`); });
When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:
function produce() { //... variationsStream(alphabet, maxLength) .on('data', combination => { //... const msg = {searchHash: searchHash, variations: batch}; channel.sendToQueue('jobs_queue', new Buffer(JSON.stringify(msg))); //... }) //... }
Any command-line input or output is written as follows:
node replier node requestor
New terms and important words are shown in bold. Words that you see on the screen, for example, in menus or dialog boxes, appear in the text like this: "To explain the problem, we will create a little web spider, a command-line application that takes in a web URL as the input and downloads its contents locally into a file."
Note
Warnings or important notes appear in a box like this.
Tip
Tips and tricks appear like this.
- Mastering macOS Programming
- 零基礎(chǔ)學(xué)Java程序設(shè)計(jì)
- Microsoft Dynamics GP 2013 Reporting, Second Edition
- Java EE 7 Performance Tuning and Optimization
- Python忍者秘籍
- Windows內(nèi)核編程
- Swift Playgrounds少兒趣編程
- Instant Lucene.NET
- Learning Continuous Integration with TeamCity
- Django 3.0入門(mén)與實(shí)踐
- Beginning C++ Game Programming
- Training Systems Using Python Statistical Modeling
- Application Development with Parse using iOS SDK
- Qt 4開(kāi)發(fā)實(shí)踐
- 官方 Scratch 3.0 編程趣味卡:讓孩子們愛(ài)上編程(全彩)