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
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
{ | |
"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 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
const express = require('express') | |
const bodyParser = require('body-parser') | |
const mongoose = require('mongoose') | |
const cors = require('cors') | |
require('dotenv').config() | |
const app = express() | |
const port = process.env.PORT || 5000 | |
// Connect to the database |
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 express = require('express') | |
const router = express.Router() | |
// create a route for default endpoint | |
router.get('/', (req, res) => { | |
res.json({ | |
message: 'Welcome to the server-side' | |
}) | |
}) |
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 express = require('express') | |
const bodyParser = require('body-parser') | |
const mongoose = require('mongoose') | |
const cors = require('cors') | |
require('dotenv').config() | |
// import routes | |
const default = require('./routes/welcome') | |
const app = express() | |
const port = process.env.PORT || 5000 |