@abrezina/dummy-data 中文文档教程

发布于 8年前 浏览 21 项目主页 更新于 3年前

dummy-data

简单的 node.js 库,用于为测试生成虚拟数据或为 anomym 数据使用假名称

install

```sh npm install --save @abrezina/dummy-data

## person generator

Generates a person object with firstname, surname and country. 
Firstname and surname are the 98 most common for the country. 
The country is one of DE, US and JP. 

### example

js var personGenerator = require('@abrezina/dummy-data').personGenerator;

var randomPerson = personGenerator.generate();

console.log('你好 %s %s 来自 %s', randomPerson.firstname, randomPerson.surname, randomPerson.country); ```

dummy-data

Simple node.js library for generating dummy data for tests or to use fake names for anomym data

install

```sh npm install --save @abrezina/dummy-data

## person generator

Generates a person object with firstname, surname and country. 
Firstname and surname are the 98 most common for the country. 
The country is one of DE, US and JP. 

### example

js var personGenerator = require('@abrezina/dummy-data').personGenerator;

var randomPerson = personGenerator.generate();

console.log('Hello %s %s from %s', randomPerson.firstname, randomPerson.surname, randomPerson.country); ```

    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文