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

  • KnockoutJS Blueprints
  • Carlo Russo
  • 212字
  • 2021-07-23 20:27:34

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: "We can include other contexts through the use of the include directive."

A block of code is set as follows:

myViewModel.categories = ko.computed(function() {
  var results = myViewModel.allCategories(),
      filterByCategory = myViewModel.selectedCategory();
  if (filterByCategory) {
    results = ko.utils.arrayFilter(results, function(category) {
      return category.name === filterByCategory;
    });
  }
  return results;
});

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

var myViewModel = {
  allCategories: ko.observableArray([]),
  selectedCategory: ko.observable(),
  selectedName: ko.observable("")
}; 

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

# npm install –g http-server

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: "Here we get the starting page, with an Error loading page."

Note

Warnings or important notes appear in a box like this.

Tip

Tips and tricks appear like this.

主站蜘蛛池模板: 中江县| 西乌| 玉林市| 新野县| 缙云县| 新昌县| 苏州市| 洪洞县| 高清| 绵阳市| 鹰潭市| 荥阳市| 荥阳市| 沙田区| 肥城市| 托克逊县| 兴文县| 五指山市| 资兴市| 西林县| 彰武县| 河源市| 宽甸| 东至县| 买车| 永定县| 睢宁县| 恩平市| 建水县| 清水河县| 天全县| 大足县| 开封市| 瑞丽市| 舞钢市| 北流市| 福泉市| 自治县| 鸡东县| 辽阳县| 巩义市|