Skip to content

Commit

Permalink
fix: developer information as a config key
Browse files Browse the repository at this point in the history
  • Loading branch information
LuXDAmore committed Jan 13, 2021
1 parent e1d39ac commit 2e3cf2e
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 24 deletions.
26 changes: 2 additions & 24 deletions lib/config.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,30 +11,8 @@ export default {
href: '',
hid: 'humans-txt',
},
// "The internet is for humans"
thanksTo: [
// Simple string can be added for comments rows
'TEAM',
// Objects { key: 'foo', value: 'bar' } for rows with different values
{
key: 'Plugin maker',
value: 'Luca Iaconelli',
},
{
key: 'From',
value: 'Faenza, Italy',
},
{
key: 'Twitter',
value: '@luxdamore',
},
{
key: 'Instagram',
value: 'https://www.instagram.com/luxdamore',
},
// Falsy values for empty-lines
false,
],
keepDevelopersInformations: true, // Keep info of my work in your `humans.txt` file 😍
thanksTo: [],
site: [
'SITE',
{
Expand Down
22 changes: 22 additions & 0 deletions lib/module.js
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,28 @@ export default async function nuxtHumansTxt(

}

// Add developers info
configuration.keepDevelopersInformations && data.push(
false,
'BACKSTAGE',
{
key: 'HumansTxt Plugin developer',
value: 'Luca Iaconelli',
},
{
key: 'From',
value: 'Faenza, Italy',
},
{
key: 'Twitter',
value: '@luxdamore',
},
{
key: 'Instagram',
value: 'https://www.instagram.com/luxdamore',
},
);

// Static folder path
const filepath = resolve(
this.options.srcDir,
Expand Down

0 comments on commit 2e3cf2e

Please sign in to comment.