-
Notifications
You must be signed in to change notification settings - Fork 189
/
Copy pathgenerate.js
71 lines (69 loc) · 2.15 KB
/
generate.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
const faker = require("faker");
const _ = require("lodash");
faker.locale = "en_IND";
module.exports = function() {
return {
tweets: _.times(30, function(index) {
return {
id: index,
user: {
name: faker.name.findName(),
username: faker.internet.userName(),
avatar: faker.image.avatar(),
cover: faker.image.image(),
bio: faker.lorem.sentence(),
location: faker.address.city(),
following: faker.random.number(1000),
followers: faker.random.number(10000)
},
time: faker.date.recent(10),
tweetContent: faker.lorem.sentences(2),
likes: faker.random.number(500),
retweets: faker.random.number(500),
replies: faker.random.number(500)
};
}),
userTweets: _.times(20, function(index) {
return {
id: index,
tweetContent: faker.lorem.sentences(2),
likes: faker.random.number(500),
retweets: faker.random.number(500),
replies: faker.random.number(500)
};
}),
login: {
username: "Batman",
password: "bruce",
name: "Batman",
bio: "The watchful protector",
location: "Gotham",
following: 0,
followers: 999,
cover:
"http://awesomwallpaper.com/img2/D4996B4DDE3D3141/batman-minimalistic-dark-dc-comics-bat-grey-logos-simple-batman-logo.jpg",
avatar:
"https://i.pinimg.com/originals/21/75/65/21756520fd48715a506661964c6ddf7a.jpg"
},
tweetReplies: _.times(10, function(index) {
return {
id: index,
user: {
name: faker.name.findName(),
username: faker.internet.userName(),
avatar: faker.image.avatar(),
cover: faker.image.image(),
bio: faker.lorem.sentence(),
location: faker.address.city(),
following: faker.random.number(1000),
followers: faker.random.number(10000)
},
time: faker.date.recent(10),
tweetContent: faker.lorem.sentences(2),
likes: faker.random.number(10),
retweets: faker.random.number(8),
replies: faker.random.number(5)
};
})
};
};