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
async function updateUser(token) { | |
let cancelled = false; | |
// we don't reject, since we don't have access to | |
// the returned promise | |
// so we just don't call other functions, and reject | |
// in the end | |
token.cancel = () => { | |
cancelled = true; | |
}; |
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
function CoffeeMachine(power, capacity) { | |
Machine.apply(this, arguments); | |
let waterAmount; | |
const WATER_HEAT_CAPACITY = 4200; | |
let timerId; | |
console.log('Create coffee machine with capacity of ' + power + ' vt'); | |
this.setWaterAmount = function (amount) { | |
if (amount < 0) throw new Error('The number must be positive'); | |
if (amount > capacity) throw new Error('Do not add more water then ' + capacity); |
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
<? | |
require($_SERVER["DOCUMENT_ROOT"] . "/bitrix/header.php"); | |
$APPLICATION->SetTitle("1С-Битрикс: Управление сайтом"); | |
CModule::IncludeModule('iblock'); | |
$arrConcert = array(); | |
$res3 = CIBlockElement::GetList(array('PROPERTY_DATE' => 'ASC'),array( 'IBLOCK_ID' => 1,)); | |
while ($obj = $res3->GetNextElement()){ |
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
const PATH = require('path'); | |
const WEBPACK = require('webpack'); | |
const HTML_WEBPACK_PLUGIN = require('html-webpack-plugin'); | |
const MERGE = require('webpack-merge'); | |
const PUG = require('./webpack/pug'); | |
const DEVSERVER = require('./webpack/devserver'); | |
const CSS = require('./webpack/css'); | |
const FONTS = require('./webpack/fonts'); | |
const IMAGES = require('./webpack/images'); | |
const SPRITE_SVG = require('./webpack/svg-sprite'); |
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, {Component} from 'react'; | |
import {withRouter} from 'react-router-dom'; | |
import Header from "../components/header"; | |
import axios from "axios"; | |
import serialize from "form-serialize"; | |
class Jurist extends Component { | |
constructor(props) { |
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, {Component} from 'react'; | |
import {withRouter} from 'react-router-dom'; | |
import Header from "../components/header/header"; | |
import axios from 'axios'; | |
// let newarr = []; | |
class News extends Component { |
NewerOlder