Skip to content

Instantly share code, notes, and snippets.

View Dmitriy-8-Kireev's full-sized avatar
🎧
Working

DmytriyKireev Dmitriy-8-Kireev

🎧
Working
  • Moscow
View GitHub Profile
@Dmitriy-8-Kireev
Dmitriy-8-Kireev / Rest Api Fetch Api async await (проба пера:).js
Last active April 19, 2021 17:29
Мелочи по серверной части
// просто fetch
fetch("https://swapi.co/api/people/5")
.then(res => {
return res.json();
});
.then((body) => {
console.log(body)
})
// Асинхронная ф-ия
@Dmitriy-8-Kireev
Dmitriy-8-Kireev / index.js
Last active August 4, 2020 13:37
Cтандарты языка ECMAScript 2019 + Важные правила React and Redux
const defaultOpts = {
host: "local",
name: "user",
user: "admin"
};
const opts = {
host: "local",
name: "Dick",
user: "Dick",
password: "1234"
@Dmitriy-8-Kireev
Dmitriy-8-Kireev / Readme.md
Last active March 11, 2019 19:14
Основы Redux визуально

g2ys4ntpnsw

1544033336593 1544033432232

1544033586542

Store API, состоящий всего из четырех методов:

1544032696157

@Dmitriy-8-Kireev
Dmitriy-8-Kireev / Readme.md
Last active February 10, 2019 17:11
Основы тестирования
@Dmitriy-8-Kireev
Dmitriy-8-Kireev / Snippets.md
Created February 8, 2019 17:38
Full React/React Native/React Router/Redux/GraphQL/ES7/Testing/PropTypes snippets

react jsnew

@Dmitriy-8-Kireev
Dmitriy-8-Kireev / index.js
Last active February 6, 2019 09:48
Примеры возможного кода на Redux
......................................................................................................................................
Имена для action
GET_ _REQUEST получить запрос (запрос начался)
GET_ _SUCCESS получить успешный запрос (запрос получен)
{ type: 'FETCH_DATA_REQUEST' }
{ type: 'FETCH_DATA_FAILURE', error: 'Oops' }
{ type: 'FETCH_DATA_SUCCESS', payload: { ... }, meta: { ... } }
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<script id="jsbin-javascript">
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<script id="jsbin-javascript">