Getting Started with hapi.js
暫譯: 開始使用 hapi.js
John Brett
- 出版商: Packt Publishing
- 出版日期: 2016-04-11
- 售價: $1,470
- 貴賓價: 9.5 折 $1,397
- 語言: 英文
- 頁數: 156
- 裝訂: Paperback
- ISBN: 1785888188
- ISBN-13: 9781785888182
海外代購書籍(需單獨結帳)
相關主題
商品描述
Key Features
- With the help of this book, you will improve your productivity as a developer and that of your team by focusing on business logic utilizing the structure that Hapi.js provides
- You will be introduced to a real-world problem and we'll demonstrate how to use the tools Hapi provides to resolve it
- This is the only book with a learn-by-example approach
Book Description
This book will introduce hapi.js and walk you through the creation of your first working application using the out-of-the-box features hapi.js provides. Packed with real-world problems and examples, this book introduces some of the basic concepts of hapi.js and Node.js and takes you through the typical journey you'll face when developing an application. Starting with easier concepts such as routing requests, building APIs serving JSON, using templates to build websites and applications, and connecting databases, we then move on to more complex problems such as authentication, model validation, caching, and techniques for structuring your codebase to scale gracefully. You will also develop skills to ensure your application's reliability through testing, code coverage, and logging.
By the end of this book, you'll be equipped with all the skills you need to build your first fully featured application. This book will be invaluable if you are investigating Node.js frameworks or planning on using hapi.js in your next project.
What you will learn
- Increase your productivity by taking advantage of the out-of-the-box features hapi.js provides
- Build secure API servers
- Create websites and applications using your favorite templating language
- Leverage hapi.js plugins to better structure your codebase
- Simplify your security workflows with the built-in authentication and authorization functionality of hapi.js
- Ensure application reliability with testing and code coverage
- Reduce code complexity using reusable validation logic with joi
- Gather insight into your application performance via logging
- Start the journey to building robust production-ready applications
About the Author
John Brett is a software engineer passionate about new technologies, open source, and building useful software while travelling the world. Starting out in Ireland with a degree in Computer Science and Software Engineer, he went on to join IBM through their premier internship Extreme Blue, later working on collaboration software as part of IBM's Software Group. There, John mainly worked with PHP and JavaScript, only working with Node.js in his spare time.
Later in his career, John moved to a growing SAAS company called D4H Technologies. As a lead engineer there, he developed tools to aid emergency response teams globally, all from a lighthouse in Dublin, Ireland. Here, John got more exposure to Node.js, leading D4H's first venture into Node using hapi.js, later joining the hapi.js core team
Table of Contents
- Introducing hapi.js
- Adding Functionality by Routing Requests
- Structuring Your Codebase with Plugins
- Adding Tests and the Importance of 100% Code Coverage
- Securing Applications with Authentication and Authorization
- The joi of Reusable Validation
- Making Your Application Production Ready
商品描述(中文翻譯)
#### 主要特點
- 在本書的幫助下,您將通過專注於業務邏輯,利用 Hapi.js 提供的結構來提高您和團隊的開發生產力。
- 您將接觸到一個真實世界的問題,我們將演示如何使用 Hapi 提供的工具來解決它。
- 這是唯一一本採用實例學習方法的書籍。
#### 書籍描述
本書將介紹 hapi.js,並引導您使用 hapi.js 提供的即用功能創建您的第一個工作應用程式。本書充滿了真實世界的問題和範例,介紹了一些 hapi.js 和 Node.js 的基本概念,並帶您經歷開發應用程式時所面臨的典型旅程。從較簡單的概念開始,例如路由請求、構建提供 JSON 的 API、使用模板構建網站和應用程式,以及連接資料庫,然後轉向更複雜的問題,例如身份驗證、模型驗證、快取,以及結構化您的程式碼庫以便於擴展的技術。您還將發展確保應用程式可靠性的技能,包括測試、程式碼覆蓋率和日誌記錄。
在本書結束時,您將具備構建第一個完整功能應用程式所需的所有技能。如果您正在研究 Node.js 框架或計劃在下一個項目中使用 hapi.js,本書將是無價的。
#### 您將學到什麼
- 通過利用 hapi.js 提供的即用功能來提高您的生產力。
- 構建安全的 API 伺服器。
- 使用您喜愛的模板語言創建網站和應用程式。
- 利用 hapi.js 插件更好地結構化您的程式碼庫。
- 通過 hapi.js 的內建身份驗證和授權功能簡化您的安全工作流程。
- 通過測試和程式碼覆蓋率確保應用程式的可靠性。
- 使用可重用的驗證邏輯與 joi 減少程式碼複雜性。
- 通過日誌記錄獲取應用程式性能的見解。
- 開始構建穩健的生產就緒應用程式的旅程。
#### 關於作者
**John Brett** 是一位熱衷於新技術、開源和在環球旅行中構建有用軟體的軟體工程師。他在愛爾蘭開始了他的職業生涯,擁有計算機科學和軟體工程的學位,後來通過 IBM 的頂尖實習計畫 Extreme Blue 加入了 IBM,並作為 IBM 軟體集團的一部分從事協作軟體的工作。在那裡,John 主要使用 PHP 和 JavaScript,僅在空閒時間使用 Node.js。
在職業生涯的後期,John 轉到一家名為 D4H Technologies 的成長中的 SAAS 公司。作為那裡的首席工程師,他開發了工具以協助全球的緊急應變團隊,所有這一切都是在愛爾蘭都柏林的一座燈塔中進行的。在這裡,John 獲得了更多使用 Node.js 的機會,領導 D4H 首次使用 hapi.js 進入 Node,並後來加入了 hapi.js 核心團隊。
#### 目錄
1. 介紹 hapi.js
2. 通過路由請求添加功能
3. 使用插件結構化您的程式碼庫
4. 添加測試及 100% 程式碼覆蓋率的重要性
5. 通過身份驗證和授權保護應用程式
6. 可重用驗證的 joi
7. 使您的應用程式準備好進入生產環境