Client requires an application that will allow the manager to generate a webpage that displays their teams basic info with the roster ouput.
The project must generate a team.html
page in the output
directory, that displays a nicely formatted team roster. Each team member should display the following in no particular order:
-
Name
-
Role
-
ID
-
Role-specific property (School, link to GitHub profile, or office number)
-
Use the Inquirer npm package to prompt the user for their email, id, and specific information based on their role with the company. For instance, an intern may provide their school, whereas an engineer may provide their GitHub username.
-
The app will run as a Node CLI to gather information about each employee.
-
Below is an example of the what application looks like.
In the Develop
folder, there is a package.json
, so make sure to npm install
.
Enter node app.js
Select manager using the arrow keys. Enter the information per the command line questions asked. Repeat for engineer and intern.
Once complete, select quit, and the team.html file will be generated in the Ouput directory.
The dependencies are, jest for running the provided tests, and inquirer for collecting input from the user.
There are also unit tests to help you build the classes necessary.
It is recommended that you follow this workflow:
- Run tests
- Create or update classes to pass a single test case
- Repeat
🎗 Remember, you can run the tests at any time with npm run test
The directory structure is below:
lib/ // classes and helper code
output/ // rendered output
templates/ // HTML template(s)
test/ // jest tests
Employee.test.js
Engineer.test.js
Intern.test.js
Manager.test.js
app.js // Runs the application
The project must have the these classes: Employee
, Manager
, Engineer
,
Intern
. The tests for these classes in the tests
directory must all pass.
The first class is an Employee
parent class with the following properties and
methods:
- name
- id
- getName()
- getId()
- getEmail()
- getRole() // Returns 'Employee'
© 2019 Trilogy Education Services, a 2U, Inc. brand. All Rights Reserved.