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

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:

"In the preceding case, the setTimeout() method is provided by JavaScript (Node.js) API."

A block of code is set as follows:

var http = require('http');
http.createServer(function(req, res) {
res.writeHead(200, { 'Content-Type': 'text/plain' });
res.end('Hello World\n');
}).listen(8080, 'localhost');
console.log('Server running at http://localhost:8080');

When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:

app.engine('Handlebars', exphbs.create({ 
    defaultLayout: 'main', 
    layoutsDir: app.get('views') + '/layouts', 
    partialsDir: [app.get('views') + '/partials'], 
    helpers: { 
        timeago: (timestamp)=> { 
            return moment(timestamp).startOf('minute').fromNow(); 
        } 
    } 
}).engine); 

Any command-line input or output is written as follows:

$ sudo apt-get install python-software-properties
$ sudo curl -sL https://deb.nodesource.com/setup_8.x | sudo -E bash -
$ sudo apt-get install nodejs

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:

A great alternative on the Mac is iTerm2.

Warnings or important notes appear in a box like this.
Tips and tricks appear like this.
主站蜘蛛池模板: 临夏县| 始兴县| 平乐县| 邵东县| 库车县| 咸丰县| 高雄市| 华容县| 平泉县| 简阳市| 乌拉特前旗| 叶城县| 阿克| 海丰县| 竹北市| 车致| 铁力市| 繁昌县| 涪陵区| 阳江市| 措美县| 和田市| 刚察县| 自贡市| 红安县| 腾冲县| 小金县| 昌邑市| 随州市| 乌拉特后旗| 泽州县| 伊宁市| 九龙县| 南澳县| 桃江县| 新乐市| 衡山县| 克山县| 错那县| 鄂托克前旗| 兰坪|