This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const path = require('path') | |
| const HtmlWebpackPlugin = require('html-webpack-plugin') | |
| module.exports = { | |
| entry: "./client/src/index.js", | |
| output: { | |
| path: path.resolve(__dirname, "./dist"), | |
| filename: "index-bundle.js" | |
| }, | |
| module: { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "extends": [ | |
| "eslint:recommended" | |
| ], | |
| "plugins": [ | |
| "react", | |
| "jsx-a11y", | |
| "import" | |
| ], | |
| "parserOptions": { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const assert = require('assert'); | |
| const { add, substract, divide, multiply, validateNumbers } = require('./operations') | |
| it ('correctly calculates the sum of 1 and 3', () => { | |
| assert.equal(add(1, 3), 4); | |
| }) | |
| it ('correctly calculates the difference of 33 and 3', () => { | |
| assert.equal(substract(33, 3), 30); | |
| }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const add = (x, y) => (+x) + (+y); | |
| const substract = (x, y) => (+x) - (+y); | |
| const multiply = (x, y) => (+x) * (+y); | |
| const divide = (x, y) => (+x) / (+y); | |
| const validateNumbers = (x, y) => { | |
| if (isNaN(x) || isNaN(y)) { | |
| return false; | |
| } | |
| return true |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| const assert = require('assert'); | |
| const { add, substract, divide, multiply, validateNumbers } = require('./operations') | |
| it ('correctly calculates the sum of 1 and 3', () => { | |
| assert.equal(add(1, 3), 4); | |
| }) | |
| it ('correctly calculates the difference of 33 and 3', () => { | |
| assert.equal(substract(33, 3), 30); | |
| }) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| .contact_us { | |
| display: flex; | |
| height: auto; | |
| background: #1d1e22; | |
| flex-direction: column; | |
| justify-content: flex-start; | |
| align-items: center; | |
| } | |
| .contact_us h3 { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| @media (max-width: 680px) { | |
| header { | |
| flex-direction: column !important; | |
| nav { | |
| margin-top: 1rem; | |
| } | |
| } | |
| .course, .pricing { | |
| height: auto; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <div class="main"> | |
| <header id="header" class="header"> | |
| <div class="logo"> | |
| <img id="header-img" src="https://2rbfd03pmmcu3pkvqf1xl71z-wpengine.netdna-ssl.com/wp-content/uploads/2017/01/logo.png" alt="CW logo"> <span>courseWare</span> | |
| </div> | |
| <nav id="nav-bar"> | |
| <ul> | |
| <li> | |
| <a class="nav-link" href="#courses">Courses</a> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <div class="main"> | |
| <header id="header" class="header"> | |
| <div class="logo"> | |
| <img id="header-img" src="https://2rbfd03pmmcu3pkvqf1xl71z-wpengine.netdna-ssl.com/wp-content/uploads/2017/01/logo.png" alt="CW logo"> <span>courseWare</span> | |
| </div> | |
| <nav id="nav-bar"> | |
| <ul> | |
| <li> | |
| <a class="nav-link" href="#courses">Courses</a> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // create state | |
| const formDetails = { | |
| user: { | |
| fullname: "", | |
| username: "", | |
| email: "", | |
| password: "", | |
| rePassword: "", | |
| occupation: "" | |
| }, |