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
echo "deb [ arch=amd64,arm64 signed-by=/usr/share/keyrings/mongodb-server-8.0.gpg ] https://repo.mongodb.org/apt/ubuntu noble/mongodb-org/8.0 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-8.0.list |
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
# /etc/nginx/mime.types | |
types { | |
font/ttf ttf; | |
font/opentype otf; | |
text/html html htm shtml; | |
text/css css; | |
text/xml xml; | |
image/gif gif; | |
image/jpeg jpeg jpg; | |
application/javascript js; |
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
# remove specific file from git cache | |
git rm --cached filename | |
# remove all files from git cache | |
git rm -r --cached . | |
git add . | |
git commit -m ".gitignore is now working" |
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
// note: encoded data is NOT encrypted | |
const crypto = require('crypto'); | |
const secret = '20BBEBB8-DCC1-4544-AD32-7F3973CCED7A'; | |
function createDigest(encodedData, format) { | |
return crypto | |
.createHmac('sha256', secret) | |
.update(encodedData) | |
.digest(format); |
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 React from 'react' | |
import Button from 'react-bootstrap/Button'; | |
import * as FileSaver from 'file-saver'; | |
import * as XLSX from 'xlsx'; | |
export const ExportCSV = ({csvData, fileName}) => { | |
const fileType = 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet;charset=UTF-8'; | |
const fileExtension = '.xlsx'; |
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
server { | |
root /var/www/html; | |
index index.html index.htm index.nginx-debian.html; | |
server_name example.com; | |
include /etc/nginx/mime.types; | |
} | |
server { | |
if ($host = example.com) { |
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
data = { | |
"pazartesi": 0, | |
"sali": 0, | |
"carsamba": 0, | |
"persembe": 0, | |
"cuma": 0, | |
"cumartesi": 0, | |
"pazar": 0, | |
"toplam": 0, | |
} |
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
String.prototype.turkishtoEnglish = function () { | |
return this.replace('Ğ','g') | |
.replace('Ü','u') | |
.replace('Ş','s') | |
.replace('I','i') | |
.replace('İ','i') | |
.replace('Ö','o') | |
.replace('Ç','c') | |
.replace('ğ','g') | |
.replace('ü','u') |
NewerOlder