This file contains hidden or 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 handler(event) { | |
var request = event.request; | |
var response = event.response; | |
var headers = response.headers; | |
// クエリパラメーターをゴニョゴニョして、paramsオブジェクトを生成 | |
var params = parseQueryParams(request.querystring); | |
// ターゲットとする、GETパラメーターのリスト | |
var targetParams = ['id', 's', 'utm', 'utm_source', 'keyword', 'returnURL']; |
This file contains hidden or 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
[data-ie-display="block"], | |
[data-ie-display="inline-block"] { | |
display: none; | |
} | |
@media (-ms-high-contrast: none), (-ms-high-contrast: active) { | |
[data-ie-display="block"] { | |
display: block !important; | |
} |
This file contains hidden or 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
btoa(unescape(encodeURIComponent( | |
`<svg width="24" height="24" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" role="img" aria-hidden="true" focusable="false"><path d="M5 9v6h14V9H5zm11-4.8H8v1.5h8V4.2zM8 19.8h8v-1.5H8v1.5z"></path></svg>` | |
))); |
This file contains hidden or 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 glob = require("tiny-glob"); | |
(async () => { | |
let entryPoints = await glob("./assets/dev/js/**/*.js"); | |
console.log({entryPoints}); | |
})(); |
This file contains hidden or 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
for (const paint of performance.getEntriesByType('paint')) { | |
console.table({ | |
'Name': paint.name, | |
'Entry Type': paint.entryType, | |
'Start Time': paint.startTime / 1000, | |
'Duration': paint.duration / 1000, | |
}) | |
} |
This file contains hidden or 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 { timing } = performance; | |
console.table({ | |
'Unload': (timing.unloadEventEnd - timing.unloadEventStart) / 1000, | |
'Redirect': (timing.redirectEnd - timing.redirectStart) / 1000, | |
'App Cache': (timing.domainLookupEnd - timing.domainLookupStart) / 1000, | |
'DNS': (timing.domainLookupEnd - timing.domainLookupStart) / 1000, | |
'TCP': (timing.connectEnd - timing.connectStart) / 1000, | |
'Request': (timing.responseStart - timing.requestStart) / 1000, | |
'Response': (timing.responseEnd - timing.responseStart) / 1000, | |
'Processing': (timing.domComplete - timing.domLoading) / 1000, |
This file contains hidden or 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 gulp = require('gulp'), | |
plumber = require('gulp-plumber'),//エラー発生時もタスクを継続する | |
notify = require('gulp-notify'),//エラー通知 | |
using = require('gulp-using'),// | |
spritesmith = require('gulp.spritesmith'); | |
gulp.task('default', function () { | |
var spriteData = gulp.src('src/images/sprite/**/*.png') | |
.pipe(plumber({ |