Sha256: 10cf8402a51d9cd608d31a63e1aafb7f6fbe083f842757871998edbcf4ea5b61
Contents?: true
Size: 1.44 KB
Versions: 11
Compression:
Stored size: 1.44 KB
Contents
const fs = require('fs'); // Define authors data const authors = [ { label: 'Ankita', name: 'Ankita', }, { label: 'Keshav', name: 'Keshav Agarwal', }, { label: 'Anushka', name: 'Anushka Guha', }, { label: 'Paavan', name: 'Thandra Paavan Kumar', }, { label: 'Arjyahi', name: 'Arjyahi Bhattacharya', }, { label: 'Nikita', name: 'Nikita Gupta', }, { label: 'Alka', name: 'Alka Bisht', }, { label: 'Siddhika', name: 'Siddhika Prajapati', }, { label: 'Krutika', name: 'Krutika', }, { label: 'Shubhangi', name: 'Shubhangi Singh', }, { label: 'Balark', name: 'Balark Singhal', }, { label: 'Udit', name: 'Udit Agarwal', }, { label: 'Pallavi', name: 'Pallavi Thakur', } ]; // Loop through each author and create a Markdown file authors.forEach(author => { const filename = `./authors/${author.name.toLowerCase().replace(' ', '-')}.md`; const htmldata = `--- layout: author label: ${author.label} authorName: ${author.name} permalink: author/${author.name.toLowerCase().replace(' ', '-')} --- ` fs.writeFile(filename, htmldata, (err) => { if (err) throw err; }); });
Version data entries
11 entries across 11 versions & 1 rubygems