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
<script type="text/javascript"> | |
$(document).ready(function () { | |
var carousel = $("#carousel").waterwheelCarousel({ | |
autoPlay : 0, | |
flankingItems:2, | |
movedToCenter: function ($item) { | |
$('#callback-output').prepend('movedToCenter: ' + $item.attr('id') + '<br/>'); | |
$item.siblings("span").css("display","block"); | |
}, | |
movingFromCenter: function ($item) { |
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
import moment from 'moment' | |
class Calendar{ | |
constructor(paramCalendarDiv, updateCallback) { | |
this.calendarDiv = paramCalendarDiv | |
this.monthPage = 0 | |
this.activatedDay = null | |
this.callbacks = [] | |
this.todayCallbacks = [] |
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 puppeteer = require('puppeteer'); | |
const logger = require('./logger'); | |
const Pool = require('./pool'); | |
const LRU = require("lru-cache"); | |
var browserErrorCount = 0; | |
var collectInterval = null; | |
var hitInterval = null; | |
async function pageAccelerate(page){ |
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
// require('./product') | |
module.exports = (sequelize, DataTypes) => ( | |
sequelize.define('product', { | |
codeNumber: { | |
type: DataTypes.STRING(50), | |
allowNull: false, | |
}, | |
kind: { | |
type: DataTypes.STRING(20), | |
allowNull: false, |
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
import "moment/locale/ko" | |
import * as moment from 'moment' | |
moment.locale('ko') | |
console.log(moment.default().format('MM-DD ddd')) // 03-10 ํ |
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
// iOS Pinch Zoom ๋๊ธฐ | |
document.documentElement.addEventListener( | |
'touchstart', | |
(event) => { | |
if (event.touches.length > 1) { | |
event.preventDefault() | |
} | |
}, | |
false |
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
import * as FirebaseAdmin from 'firebase-admin' | |
import * as serviceAccount from '../~~.json' | |
FirebaseAdmin.initializeApp({ | |
// @ts-ignore | |
credential: FirebaseAdmin.credential.cert(serviceAccount), | |
}) | |
export const sendPushMessage = async ( | |
notification: { |
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
import puppeteer from 'puppeteer' | |
import puppeteerExtra from 'puppeteer-extra' | |
import pluginStealth from 'puppeteer-extra-plugin-stealth' | |
import cloudscraper from 'cloudscraper' | |
import {User} from "../domain/user"; | |
import {accessing} from "../handlers/nasHandler"; | |
let scraper: any = cloudscraper | |
let browser; |
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
export const chunk = <T>(array: T[], chunkSize: number) => { | |
const result: T[][] = [] | |
for (let i = 0; i < array.length; i += chunkSize) | |
result.push(array.slice(i, i + chunkSize)) | |
return result | |
} |
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
/* | |
Windows 10 ์ผ๋ถ ๋ฒ์ + XP๋ฒ์ ์์ JSON ํ์ผ์ ๋ฉ๋ชจ์ฅ์ผ๋ก | |
์์ ํ ์ฌ๋์ ๊ฒฝ์ฐ utf8 ๋ก ์ ์ฅํด๋ utf8 with BOM ์ด๋ผ๋ | |
ํ์์ผ๋ก ์ ์ฅ์ด๋๋๋ฐ ์ดํ์ํน์ดํ๊ฒ ์ต์ด์ ์ด์ํ ๊ธ์๋ฅผ ์ถ๊ฐํด์ | |
fs ๊ฐ ์์ด๋์ ํฐ์ง๋๋ค, ์ด ์ค๋ฅ๋ฅผ ์์ ํ๋ ค๋ฉด ์๋ ์ฝ๋๋ฅผ ์ฐ๋ฉด ๋ฉ๋๋ค. | |
*/ | |
fs.readFile('./myconfig.json', 'utf8', function (err, data) { | |
myconfig = JSON.parse(data.toString('utf8').replace(/^\uFEFF/, '')) | |
}) |
OlderNewer