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
| #!/bin/sh | |
| . "$(dirname "$0")/_/husky.sh" | |
| echo '🏗️👷 Styling, testing and building your project before committing' | |
| # Running prettier format and eslint fix | |
| yarn format || | |
| ( |
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 CryptLib = require('cryptlib'), | |
| crypt = CryptLib | |
| plainText = 'This is the text to be encrypted' | |
| // iv = _crypt.generateRandomIV(16), //16 bytes = 128 bit | |
| key = crypt.getHashSha256('4E645267556B58703273357538782F413F4428472B4B6250655368566D597133', 32), //32 bytes = 256 bits | |
| iv = "Vmr-uU5mA2_Zr_13" | |
| cypherText = "bvtkHfZiTsY0CX6QmHhCboBwXeY9RZVPpdhhdIy6aSwCTVI7YiEGha1aXTIKY4BocGdNIbWkreQHZcTk4WE6F2tQLoVyWERYCGZotbDzxxs=" | |
| // cypherText = _crypt.encrypt(plainText, key, iv), | |
| originalText = crypt.decrypt(cypherText, key, iv); |
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
| string = "height" | |
| def getRhymePattern(string): | |
| vowel= ["a","e","i","o","u"] | |
| new_vowel = "y" | |
| first_letter = 0 | |
| last_letter = len(string)-1 | |
| substring = [] | |
| values_key = [] | |
| y_vowel = 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
| addEventListener('fetch', event => { | |
| event.respondWith(handleRequest(event.request)) | |
| }) | |
| /** | |
| * Fetch and log a request | |
| * @param {Request} request | |
| */ | |
| async function handleRequest(request) { | |
| // Parse request URL to get access to query string |
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
| addEventListener('fetch', event => { | |
| event.respondWith(handleRequest(event)) | |
| }) | |
| const BUCKET_NAME = 'modistabox-cdn' | |
| const BUCKET_URL = `http://storage.googleapis.com/${BUCKET_NAME}` | |
| async function serveAsset(event) { | |
| const url = new URL(event.request.url) | |
| const cache = caches.default |
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
| localStorage.setItem('user',JSON.stringify({"user":{"uid":"i9KHEZn2EGgL54SUeUX3rbuwM1z2","displayName":"Nilay Singh","photoURL":"https://lh5.googleusercontent.com/-JmsyqzUpLtc/AAAAAAAAAAI/AAAAAAAAAAA/ACHi3rcRIlApoJhX5AyBc_lWSB9CQWXtqA/photo.jpg","email":"[email protected]","emailVerified":true,"phoneNumber":null,"isAnonymous":false,"tenantId":null,"providerData":[{"uid":"103416359031270229591","displayName":"Nilay Singh","photoURL":"https://lh5.googleusercontent.com/-JmsyqzUpLtc/AAAAAAAAAAI/AAAAAAAAAAA/ACHi3rcRIlApoJhX5AyBc_lWSB9CQWXtqA/photo.jpg","email":"[email protected]","phoneNumber":null,"providerId":"google.com"},{"uid":"[email protected]","displayName":"Nilay Singh","photoURL":"https://lh5.googleusercontent.com/-JmsyqzUpLtc/AAAAAAAAAAI/AAAAAAAAAAA/ACHi3rcRIlApoJhX5AyBc_lWSB9CQWXtqA/photo.jpg","email":"[email protected]","phoneNumber":null,"providerId":"password"}],"apiKey":"AIzaSyBm59uh_SteEZ0JjjX8jd71bOreAvZWoJw","appName":"[DEFAULT]","authDomain":"modistabox.firebaseapp.com","stsTokenMan |
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 street = "jjjj | |
| #we need to pass this variable in full_address | |
| window.Paytabs.initWithIframe(document.body, { | |
| settings: { | |
| secret_key: | |
| "WIfjigJE0bTlJfsjysPvWHyMYYFxVsoSaEbtVU7W61hPgK8PcYk9GTVERBcN3BFdfQHaLP6RQoH79QWmPgvv9qa11nP4Yuiel0o7", | |
| merchant_id: "10045363", | |
| url_redirect: "https://9k23u.csb.app/", | |
| amount: "100", | |
| title: "John Doe", |
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
| upstream hello_django { | |
| server 10.128.0.10:8080; | |
| } | |
| server { | |
| listen 80; | |
| location / { | |
| proxy_pass http://hello_django; |
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
| class Survey(models.Model): | |
| question_name = models.TextField() | |
| question_answer = models.CharField(max_length=300,null=True, blank=True) | |
| user_id = models.CharField(max_length=200,null=True, blank=True) | |
| session_id = models.CharField(max_length=200) | |
| data = JSONField(null=True, blank=True) | |
| created = models.DateTimeField(auto_now_add=True) | |
| def __str__(self): | |
| return self.question_name |
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
| { | |
| "0": { | |
| "answer": [ | |
| "Every 2-3 weeks" | |
| ], | |
| "question": "How often would you like to be styled ?", | |
| "questionId": 28 | |
| }, | |
| "1": { | |
| "answer": [ |
NewerOlder