更新情報
・constをletに修正、問題を追加(2024/9/27)
・問題を追加(2024/7/20)
・問題を追加(2024/4/12)| var webpack = require('webpack') | |
| module.exports = function (config) { | |
| config.set({ | |
| browsers: [ 'Chrome' ], //run in Chrome | |
| browserNoActivityTimeout: 60000, | |
| singleRun: true, //just run once by default | |
| frameworks: [ 'mocha' ], //use the mocha test framework | |
| files: [ | |
| //'src/**/*.{jsx,js}', |
これはredux-middlewaresの紹介です。
Middlewareがどのようなものかついては、非常に分かりやすい記事があるのでそれを貼っておきます。
http://qiita.com/kuy/items/57c6007f3b8a9b267a8e
僕がMiddlewareを活用するようになったのは、この記事を読んでからです。
| var str = 'class ಠ_ಠ extends Array {constructor(j = "a", ...c) {const q = (({u: e}) => {return { [`s${c}`]: Symbol(j) };})({});super(j, q, ...c);}}' + | |
| 'new Promise((f) => {const a = function* (){return "\u{20BB7}".match(/./u)[0].length === 2 || true;};for (let vre of a()) {' + | |
| 'const [uw, as, he, re] = [new Set(), new WeakSet(), new Map(), new WeakMap()];break;}f(new Proxy({}, {get: (han, h) => h in han ? han[h] ' + | |
| ': "42".repeat(0o10)}));}).then(bi => new ಠ_ಠ(bi.rd));'; | |
| try { | |
| eval(str); | |
| } catch(e) { | |
| alert('Your browser does not support ES6!') | |
| } |
| #!/usr/bin/env node | |
| /* eslint-disable */ | |
| /* | |
| Usage. | |
| : Input generator.yml | |
| pkgName: '@x/y' | |
| testExtension: .test.js |
| npm i -g nativefier | |
| curl https://azu.github.io/in-site-search-javascript/index.js > index.js | |
| nativefier --name "ECMAScript" "https://tc39.github.io/ecma262/" --fast-quit --hide-window-frame --show-menu-bar --maximize --inject ./index.js |
| // jsonschema | |
| export type JSONSchema$Type$Base = { | |
| id?: string, | |
| required?: boolean | |
| } | |
| export type JSONSchema$Type$Object = JSONSchema$Type$Base & { | |
| type: 'object', | |
| properties: {[key: string]: JSONSchema$Type}, | |
| additionalProperties?: false, |
Note: I'm not involved in Prepack in any way — please correct me if I say anything incorrect below!
A few people have asked me if Prepack and Svelte are similar projects with similar goals. The answer is 'no, they're not', but let's take a moment to explore why.
Prepack describes itself as a 'partial evaluator for JavaScript'. What that means is that it will run your code in a specialised interpreter that, rather than having some effect on the world (like printing a message to the console), will track the effects that would have happened and express them more directly.
So for example if you give it this code...
| { | |
| "version": "0.2.0", | |
| "configurations": [ | |
| { | |
| "name": "Example", | |
| "type": "node", | |
| "request": "launch", | |
| "runtimeExecutable": "node", | |
| "runtimeArgs": ["--nolazy", "-r", "ts-node/register/transpile-only"], |