-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.js
44 lines (41 loc) · 1.3 KB
/
index.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
#!/usr/bin/env node
import chalk from "chalk";
import boxen from "boxen";
// Text + chalk definitions
const data = {
name: chalk.white("YL2120"),
work: chalk.white("Junior at BeCode.org"),
npm: chalk.gray("https://npmjs.com/") + chalk.red("~yl2120"),
github: chalk.gray("https://github.com/") + chalk.green("YL2120"),
npx: chalk.red("npx") + " " + chalk.white("yl2120"),
labelWork: chalk.white.bold(" Work:"),
labelTwitter: chalk.white.bold(" Twitter:"),
labelNpm: chalk.white.bold(" npm:"),
labelGitHub: chalk.white.bold(" GitHub:"),
labelLinkedIn: chalk.white.bold(" LinkedIn:"),
labelWeb: chalk.white.bold(" Web:"),
labelCard: chalk.white.bold(" Card:"),
};
const NEWLINE = "\n";
const EMPTYLINE = "";
console.log(
chalk.green(
boxen(
[
`${data.name}`,
EMPTYLINE,
`${data.labelWork} ${data.work}`,
EMPTYLINE,
`${data.labelNpm} ${data.npm}`,
`${data.labelGitHub} ${data.github}`,
EMPTYLINE,
`${data.labelCard} ${data.npx}`,
].join(NEWLINE),
{
padding: 1,
margin: 1,
borderStyle: "round",
},
),
),
);