- Learning Node.js Development
- Andrew Mead
- 240字
- 2021-06-30 18:56:50
Using the utilities of lodash
With the exports in place, we can now take advantage of some of the utilities that come with Lodash. We'll quickly explore two in this section, and we'll be exploring more throughout the book since Lodash is basically just a set of really handy utilities. Before we do, we should take a look at the documentation so we know exactly what we're getting into.
On the npm page, click the lodash link given there, or go to lodash.com and click the API Documentation page, as shown here:

You can view all of the various methods you have available to you, as shown in the following screenshot:

In our case, we'll be using command + F (Ctrl + F for Windows users) to search for _.isString. Then in the docs, we can click on it, opening it up in the main page, as shown in the following screenshot:

The _.isString is a utility that comes with lodash, and it returns true if the variable you pass in is a string, and it returns false if the value you pass in is not a string. And we can prove that by using it over in Atom. Let's use this.
- Mastering Node.js(Second Edition)
- 工業(yè)控制網(wǎng)絡(luò)安全技術(shù)與實(shí)踐
- 物聯(lián)網(wǎng)檢驗(yàn)檢測(cè)技術(shù)
- 農(nóng)產(chǎn)品物聯(lián)網(wǎng)研究與應(yīng)用
- Hands-On Full Stack Development with Spring Boot 2 and React(Second Edition)
- HTML5 Game development with ImpactJS
- Windows Server 2003 Active Directory Design and Implementation: Creating, Migrating, and Merging Networks
- Spring Cloud微服務(wù)架構(gòu)進(jìn)階
- 網(wǎng)絡(luò)的琴弦:玩轉(zhuǎn)IP看監(jiān)控
- 通信簡(jiǎn)史:從信鴿到6G+
- 物聯(lián)網(wǎng)通信技術(shù)
- Yii Application Development Cookbook(Second Edition)
- 網(wǎng)絡(luò)安全應(yīng)急響應(yīng)技術(shù)實(shí)戰(zhàn)
- 網(wǎng)管員必讀:網(wǎng)絡(luò)管理(第2版)
- Kong網(wǎng)關(guān):入門、實(shí)戰(zhàn)與進(jìn)階