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
App.jsx: | |
import React, { useState, useEffect } from 'react'; | |
import './App.css'; | |
function App() { | |
const [isLoggedIn, setIsLoggedIn] = useState(false); // початковий стан авторизації | |
const [isReady, setIsReady] = useState(false); // стан готовності компоненти | |
// імітація завантаження даних, тут може бути прелоадер |
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
1. встановити node.js за посиланням https://nodejs.org/en | |
2. виконати такі команди в терміналі git bash: | |
cd C:/Users/Alex/Desktop | |
mkdir file-server | |
cd file-server | |
npm init -y | |
npm install express multer | |
mkdir public | |
mkdir uploads |
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
<!DOCTYPE html> | |
<html lang="uk"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<title>Робота з файлами</title> | |
<style> | |
body { | |
font-family: Arial, sans-serif; | |
max-width: 800px; |
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
<!DOCTYPE html> | |
<html lang="uk"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Найкращі фільми (Axios + OOP)</title> | |
<script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script> | |
<style> | |
body { | |
font-family: Arial, sans-serif; | |
background-color: #121212; |
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
http://sunmeat.atwebpages.com/js/post_get.html: | |
<!DOCTYPE html> | |
<html lang="uk"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Відправка запиту на PHP файл</title> | |
<style> | |
body { | |
font-family: Arial, sans-serif; |
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
<!DOCTYPE html> | |
<html lang="uk"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Надсилання даних форми fetch API + валідація</title> | |
<style> | |
body { | |
font-family: Arial, sans-serif; | |
background-color: #121212; | |
color: #ffffff; |
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
<!DOCTYPE html> | |
<html lang="uk"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>async await замість промісів</title> | |
<style> | |
body { | |
font-family: 'Courier New', Courier, monospace; | |
background: linear-gradient(135deg, #0f2027, #203a43, #2c5364); | |
color: #00ffe5; |
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
<!DOCTYPE html> | |
<html lang="uk"> | |
<head> | |
<meta charset="UTF-8"> | |
<title>Проміси + АПІ</title> | |
<style> | |
body { | |
font-family: 'Courier New', Courier, monospace; | |
background: linear-gradient(135deg, #0f2027, #203a43, #2c5364); | |
color: #00ffe5; |
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
<html lang="uk"> | |
<head> | |
<meta charset="UTF-8"> | |
<style> | |
.sp { | |
position: absolute; | |
cursor: pointer; | |
background-color: greenyellow; | |
border: 3px solid greenyellow; | |
border-radius: 10px; |
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
<!doctype html> | |
<html lang="uk"> | |
<head> | |
<title>П'ятнашки</title> | |
<meta charset="UTF-8"> | |
<style> | |
/* стилі для квадратів гри */ | |
.square { | |
position: absolute; | |
width: 137px; |
NewerOlder