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
import * as crypto from 'crypto' | |
const merchantSecret = 'secret' | |
const hash = 'sha256' | |
const encoding = 'base64' | |
const payload = { | |
id: 123, | |
somethingElse: 'not 123' | |
} |
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
console.log('challenge accepted'); | |
let x = { | |
// save the real value | |
_value: 0, | |
// get the value implicity when needed | |
valueOf: function getX() { | |
return (x._value += 5); | |
} | |
} |
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
// Copyright 2021 Lableb | |
/** | |
* Lodash debounce with cancellation capabilities | |
* | |
* @author Louay Al-osh | |
*/ | |