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
| import React from 'react'; | |
| import { BrowserRouter as Router, Switch, Route } from 'react-router-dom'; | |
| import Navigation from './components/Navigation'; | |
| import Home from './components/Home'; | |
| import Transactions from './components/Transactions'; | |
| import Budgets from './components/Budgets'; | |
| import Settings from './components/Settings'; | |
| function App() { | |
| return ( |
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
| export default function generateSeries(x) { | |
| const series = [x]; | |
| let n = x; | |
| while (n !== 1) { | |
| if (n % 2 === 0) { | |
| n = n / 2; | |
| } else { | |
| n = 3 * n + 1; | |
| } | |
| series.push(n); |
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
| import React, { useState, useEffect } from "react"; | |
| import { useHistory } from "react-router-dom"; | |
| import { auth } from "../firebase"; | |
| import { signInWithEmailAndPassword } from "firebase/auth"; | |
| export default function LoginForm(props) { | |
| const [emailId, updateEmailId] = useState(""); | |
| const [password, updatePassword] = useState(""); | |
| useEffect(() => { | |
| if (props.isLoggedIn) { | |
| history.push("/app"); |
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
| // Print values using console log keywords | |
| // console.log("Welcome to javascript session"); | |
| // console.log("Today is Sunday"); | |
| // console.log("hello world"); | |
| // Comments in Javascript | |
| // Single line comment | |
| /* | |
| This is a multiline comment | |
| JS is an interpreted language |
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 cors = require('cors') | |
| const app = express() | |
| const axios = require('axios') | |
| app.use(cors()) | |
| app.use(express.json()) | |
| app.get('/jobs_list', async function (req, res) { | |
| const skill = req.query.skill; | |
| axios.get(`https://jobs.github.com/positions.json?search=${skill}`) | |
| .then(function (response) { |
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
| .alert { color: #000;} | |
| .alert__title { padding: 10px;} | |
| .track__title:hover, .track-title:focus { color: blue} |
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
| .alert { | |
| color: #000; | |
| &__title { | |
| paddding: 10px; | |
| &:hover { | |
| color: blue; | |
| } | |
| } | |
| } |
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
| .list { | |
| color: beige; | |
| } | |
| .alert { | |
| color: beige; | |
| } |
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
| $primary-color: beige | |
| .list | |
| color: $primary-color | |
| .alert | |
| color: $primary-color |
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
| /* SCSS */ | |
| $primary-color: beige; | |
| .list { | |
| color: $primary-color; | |
| } | |
| .alert { | |
| color: $primary-color; | |
| } |
NewerOlder