Skip to content

vilmaq/team-html-generator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Team-HTML-Generator

Description

This is a Node.js command-line application that takes in information about employees on a software engineering team and generates an HTML webpage that renders card for each added employee. Technologies used: JS, Node JS, HTML, CSS.

The application includes Employee, Manager, Engineer, and Intern classes. The tests for these classes are in the _tests_ directory.

The first class Employee is a parent class with the following properties and methods:

  • name

  • id

  • email

  • getName()

  • getId()

  • getEmail()

  • getRole()—returns 'Employee'

The other three classes (Manager, Engineer, Intern) will extend Employee.

In addition to Employee's properties and methods, Manager has also the following:

  • officeNumber

  • getRole()—overridden to return 'Manager'

In addition to Employee's properties and methods, Engineer has also the following:

  • github—GitHub username

  • getGithub()

  • getRole()—overridden to return 'Engineer'

In addition to Employee's properties and methods, Intern has also the following:

  • school

  • getSchool()

  • getRole()—overridden to return 'Intern'

In this project the following packages have been used:

Steps to Get Started

git clone [email protected]:vilmaq/team-html-generator.git
cd team-html-generator
npm init -y
npm i inquirer
npm i jest --save-dev

Add the following in the package.json for an easy start and testing of the application:

"scripts": {},
"start": "node src/index.js",
"test": "jest --verbose --coverage",
"test:watch": "jest --verbose --watch",

To run the application:

npm run start

To test the application:

npm run test
npm run test:watch

Directory structure

__tests__/			// jest tests
  Employee.test.js
  Engineer.test.js
  Intern.test.js
  Manager.test.js
dist/               // rendered output
src/				// template helper code
   lib/				// classes: Manager, Engineer, Intern
index.js		// runs the application

GitHub & Walkthrough Video

Sample of Generated HTML

sample.html

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published