This file contains 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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>Personal Blog</title> | |
</head> |
This file contains 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 url("https://fonts.googleapis.com/css2?family=Fraunces:wght@800&family=Montserrat:wght@500&family=Oswald:wght@500&family=Quicksand&family=Ubuntu:wght@500&display=swap"); | |
* { | |
padding: 0; | |
margin: 0; | |
box-sizing: border-box; | |
scroll-behavior: smooth; | |
} | |
body { |
This file contains 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
let heading = document.getElementById("heading"); | |
let head2 = document.getElementById("head2"); | |
let para = document.getElementById("para"); | |
let four = document.getElementById("four"); | |
let five = document.getElementById("five"); | |
let six = document.getElementById("six"); | |
let btn1 = document.getElementById("btn1"); | |
let btn2 = document.getElementById("btn2"); | |
let rows = document.getElementById("rows"); | |
let image = document.getElementById("image"); |
This file contains 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 Calculator from './Calculator'; | |
import Navbar from './Navbar'; | |
const App = () => { | |
return ( | |
<> | |
<Navbar /> | |
<Calculator /> | |
</> |
This file contains 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 '../node_modules/bootstrap/dist/css/bootstrap.min.css'; | |
import '../node_modules/bootstrap/dist/js/bootstrap.bundle'; | |
const Navbar = () => { | |
return ( | |
<> | |
<nav className="navbar navbar-expand-lg navbar-light"> | |
<div className="container-fluid"> | |
<a className="navbar-brand" href="/">Navbar</a> |
This file contains 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 Button from '@material-ui/core/Button'; | |
import '../node_modules/bootstrap/dist/css/bootstrap.min.css'; | |
import '../node_modules/bootstrap/dist/js/bootstrap.bundle'; | |
const Calculator = () => { | |
return ( | |
<> | |
<div className="container"> | |
<h1>Hello World</h1> |
This file contains 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 } from 'react'; | |
import Button from '@material-ui/core/Button'; | |
import AddIcon from '@material-ui/icons/Add'; | |
import '../node_modules/bootstrap/dist/css/bootstrap.min.css'; | |
import '../node_modules/bootstrap/dist/js/bootstrap.bundle'; | |
const Calculator = () => { | |
const [add, setAdd] = useState(0); | |
const increment = () => { | |
setAdd(add + 1); |
This file contains 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 '../node_modules/bootstrap/dist/css/bootstrap.min.css'; | |
import '../node_modules/bootstrap/dist/js/bootstrap.bundle'; | |
const Calculator = () => { | |
const [width, setWidth] = useState(window.screen.width); | |
useEffect(() => { | |
window.addEventListener('resize', changeWidth); | |
console.log("Your Width Is Changed To " + width); | |
return () => { |
This file contains 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, { createContext } from 'react'; | |
import ComponentA from './ComponentA'; | |
const FirstName = createContext(); | |
const LastName = createContext(); | |
const UseContext = () => { | |
return ( | |
<> |
This file contains 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 ComponentB from './ComponentB'; | |
const ComponentA = () => { | |
return ( | |
<> | |
<ComponentB/> | |
</> | |
); | |
} |
OlderNewer