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
<ItemGroup> | |
<ExcludeFromPackageFolders Include="node_modules"> | |
<FromTarget>Build</FromTarget> | |
</ExcludeFromPackageFolders> | |
</ItemGroup> | |
<PropertyGroup> | |
<DefaultItemExcludes>node_modules/**;$(DefaultItemExcludes)</DefaultItemExcludes> | |
</PropertyGroup> |
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
rust debug in vscode: | |
install: RLS, C/C++ | |
based on: | |
https://www.brycevandyk.com/debug-rust-on-windows-with-visual-studio-code-and-the-msvc-debugger/ | |
C++ (Windows). | |
launch.json | |
{ |
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
{ | |
"scripts": { | |
"test": "echo \"Error: no test specified\" && exit 1", | |
"watch": "webpack --watch --devtool eval-source-map", | |
"build": "webpack -p" | |
}, | |
} |
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 BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin; | |
const ManifestPlugin = require('webpack-manifest-plugin'); | |
const CleanWebpackPlugin = require('clean-webpack-plugin'); | |
plugins = [ | |
new webpack.EnvironmentPlugin(['NODE_ENV']), | |
new ManifestPlugin(), | |
new CleanWebpackPlugin([__dirname + '/src/Website/Scripts/dist']), |
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
Show hidden characters
{ | |
"presets": [ | |
["@babel/preset-env", { | |
"modules": false, | |
"targets": { | |
"browsers": ["last 2 versions", "ie >= 8", "safari >= 7"], | |
}, | |
"useBuiltIns": "usage", | |
"debug": 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
<html> | |
<head> | |
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css"> | |
<style type="text/css"> | |
.stars { | |
position: relative; | |
width: 70px; | |
height: 20px; | |
} |
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 onKonamiCode(cb) { | |
var input = ''; | |
var key = '38384040373937396665'; | |
document.addEventListener('keydown', function (e) { | |
input += ("" + e.keyCode); | |
console.log(input, key.indexOf(input)); | |
if (input === key) { | |
return cb(); | |
} | |
if (!key.indexOf(input)) 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
function eventEmitter() { | |
var events = {}; | |
return { | |
bind: function bind(name, cb) { | |
events[name] = events[name] || []; | |
events[name].push(cb); | |
}, | |
unBind: function unBind(name, cb) { | |
if (!events[name]) return; | |
events[name].splice(events[name].indexOf(cb), 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
var codes = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-_".split(''); | |
function to64(d) { | |
var r = d % 64; | |
var result; | |
if (d - r == 0) | |
result = codes[r]; | |
else | |
result = to64((d - r) / 64) + codes[r]; | |
return result; |
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
/** | |
* Promises All | |
*/ | |
(function () { | |
var promises = [ | |
Promise.resolve('1st'), | |
Promise.resolve('2nd'), | |
Promise.resolve('...'), | |
Promise.resolve('n'), |
NewerOlder