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> | |
<title>Мой сайт</title> | |
<style> | |
p { | |
color: red; | |
} | |
</style> | |
</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
<!DOCTYPE html> | |
<head> | |
<script type='text/javascript'> | |
window.onload = function () { | |
var video = document.getElementById('videoId') | |
var canvas = document.getElementById('canvasId') | |
canvas.style.display = 'block' | |
// fake loading | |
setTimeout(() => { | |
// start when video loaded |
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
// full version (with functions for cluster) can be found here: | |
// https://github.com/kikill95/profiler-demo/blob/master/timer.js | |
/* | |
** Example of usage (more samples there - https://github.com/kikill95/profiler-demo) | |
... | |
timer.time('metrics', 'wrapper') | |
... | |
timer.timeEnd('metrics', 'wrapper') |
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
// Convert Excel dates into JS date objects | |
// | |
// @param excelDate {Number} | |
// @return {Date} | |
function getJsDateFromExcel(excelDate) { | |
// JavaScript dates can be constructed by passing milliseconds | |
// since the Unix epoch (January 1, 1970) example: new Date(12312512312); |
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> | |
<title>Filereader</title> | |
<style> | |
div { | |
font-family: "Helvetica Neue"; | |
line-height:22px; | |
font-size:15px; | |
margin:10px 0; |
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 Location from 'Location' | |
import { | |
AppRegistry, | |
asset, | |
Pano, | |
View, | |
VrButton, | |
Model, | |
Sound, |
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 {VRInstance} from 'react-vr-web' | |
import * as SimpleRaycaster from 'simple-raycaster' | |
function init (bundle, parent, options) { | |
const vr = new VRInstance(bundle, 'gdg_reactvr', parent, { | |
raycasters: [ | |
SimpleRaycaster // Add SimpleRaycaster to the options | |
], | |
cursorVisibility: 'visible', // Add cursorVisibility | |
...options |
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
1. // isPrime - Returns true or false, indicating whether the given number is prime. | |
isPrime(0) // false | |
isPrime(1) // false | |
isPrime(17) // true | |
isPrime(10000000000000) // false | |
2. // factorial - Returns a number that is the factorial of the given number. | |
factorial(0) // 1 | |
factorial(1) // 1 | |
factorial(6) // 720 |
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 webpack = require('webpack') | |
const ExtractTextPlugin = require('extract-text-webpack-plugin') | |
const path = require('path') | |
const sourcePath = path.resolve(__dirname, 'public') | |
const isProduction = process.env.NODE_ENV === 'production' | |
const stats = { | |
assets: 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
// imports es6 | |
import defaultMember from "module-name"; | |
import * as name from "module-name"; | |
import { member } from "module-name"; | |
import { member as alias } from "module-name"; | |
import { member1 , member2 } from "module-name"; | |
import { member1 , member2 as alias2 } from "module-name"; | |
import defaultMember from "module-name"; | |
import defaultMember, * as name from "module-name"; | |
import "module-name"; |
NewerOlder