npm init -y
npm i --save-dev nodemon
npm add babel-preset-env babel-cli
Create a .babelrc config in your project root. Insert the following
{
"presets": ["env"]
| <?php | |
| /** | |
| * TimThumb by Ben Gillbanks and Mark Maunder | |
| * Based on work done by Tim McDaniels and Darren Hoyt | |
| * http://code.google.com/p/timthumb/ | |
| * | |
| * GNU General Public License, version 2 | |
| * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html | |
| * | |
| * Examples and documentation available on the project homepage |
| //License CC0 1.0: https://creativecommons.org/publicdomain/zero/1.0/ | |
| class Deferred extends React.Component { | |
| constructor(props) { | |
| super(props); | |
| this.state = { | |
| value: '' | |
| }; | |
| } | |
| componentDidMount() { |
| { | |
| "scripts": { | |
| "build": "npm run build:es2015 && npm run build:esm && npm run build:cjs && npm run build:umd && npm run build:umd:min", | |
| "build:es2015": "tsc --module es2015 --target es2015 --outDir dist/es2015", | |
| "build:esm": "tsc --module es2015 --target es5 --outDir dist/esm", | |
| "build:cjs": "tsc --module commonjs --target es5 --outDir dist/cjs", | |
| "build:umd": "rollup dist/esm/index.js --format umd --name YourLibrary --sourceMap --output dist/umd/yourlibrary.js", | |
| "build:umd:min": "cd dist/umd && uglifyjs --compress --mangle --source-map --screw-ie8 --comments --o yourlibrary.min.js -- yourlibrary.js && gzip yourlibrary.min.js -c > yourlibrary.min.js.gz", | |
| } | |
| } |
| const io = require('socket.io-client'); | |
| const socket = io('http://localhost:3000', { | |
| transportOptions: { | |
| polling: { | |
| extraHeaders: { | |
| 'Authorization': 'Bearer abc', | |
| }, | |
| }, | |
| }, |
| class NeuMF(torch.nn.Module): | |
| def __init__(self, config): | |
| super(NeuMF, self).__init__() | |
| #mf part | |
| self.embedding_user_mf = torch.nn.Embedding(num_embeddings=self.num_users, embedding_dim=self.latent_dim_mf) | |
| self.embedding_item_mf = torch.nn.Embedding(num_embeddings=self.num_items, embedding_dim=self.latent_dim_mf) | |
| #mlp part | |
| self.embedding_user_mlp = torch.nn.Embedding(num_embeddings=self.num_users, embedding_dim=self.latent_dim_mlp) |
| #!/usr/bin/env python | |
| # Dependencies: | |
| # ffmpeg: https://www.ffmpeg.org/download.html | |
| # fpcalc: https://acoustid.org/chromaprint | |
| from datetime import datetime | |
| import os | |
| import os.path | |
| import json | |
| import math | |
| import shutil |
| 'use strict'; | |
| !function() { | |
| /** | |
| * @return {?} | |
| */ | |
| function t$jscomp$0() { | |
| return "cf-marker-" + Math.random().toString().slice(2); | |
| } | |
| /** | |
| * @return {undefined} |
| const a = [{ | |
| 'id': '1', | |
| 'name': 'a1' | |
| }, { | |
| 'id': '2', | |
| 'name': 'a2' | |
| }, { | |
| 'id': '3', | |
| 'name': 'a3' | |
| }]; |
| //License CC0 1.0: https://creativecommons.org/publicdomain/zero/1.0/ | |
| class Deferred extends React.Component { | |
| constructor(props) { | |
| super(props); | |
| this.state = { | |
| value: '' | |
| }; | |
| } | |
| componentDidMount() { |