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
module.exports = api => { | |
const babelEnv = api.env(); | |
const plugins = []; | |
if (babelEnv !== 'development') { | |
plugins.push('transform-remove-console'); | |
} | |
return { | |
presets: ['module:metro-react-native-babel-preset'], | |
plugins, | |
}; |
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
//Define lists of words and symbols to filter out | |
//Numbers and similar | |
var stopwordnumbers = [“once”, “twice”, “thrice”, “first”, “second”, “third”, “fourth”, “fifth”, “sixth”, “seventh”, “nineth”, “tenth”, “1”, “2”, “3”, “4”, “5”, “6”, “7”, “8”, “9”, “0”, “one”, “two”, “three”, “four”, “five”, “six”, “seven”, “eight”, “nine”, “ten”, , “eleven”, “twelve”, “thirteen”, “fourteen”, “fifteen”, “sixteen”, “seventeen”, “eighteen”, “tweenty”, “thirty”, “fourty”, “fifty”, “sixty”, “seventy”, “eighty”, “ninety”, “hundred”, “hundreds”, “and”, “-”, “thousand”, “thousands”, “million”, “millions”, “billion”, “billions” ]; | |
//Symbols | |
var stopwordsymbols = [“+”,”-”,”*”,”%”,”/”,”?”,”!”,”^”,”’”,”\””,”,”,”;”,”\\”,”.”] | |
//Very short words and others, compiled by me from several resources including https://github.com/Yoast/YoastSEO.js/blob/develop/src/config/stopwords.js and https://gist.github.com/sebleier/554280 | |
var stopwordsmin3=["if", "or", "in", “a”,”an”,”cool”,”good”,”yep”,”yeah”,”but”,”yes”,”no”,”nop”,”nope”,”sth”,”somethi |
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
/** | |
* @param {number[]} height | |
* @return {number} | |
*/ | |
var trap = function (height) { | |
function measureWater(currentValue, prevItems, nextItems) { | |
const lastPrev = isFinite(Math.max(...prevItems)) ? Math.max(...prevItems) : 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
import { CSSProperties } from "react"; | |
import { clamp, MotionValue, useMotionValueEvent } from "framer-motion"; | |
import React, { useEffect, useRef } from "react"; | |
interface ImageSequenceProps { | |
progress: MotionValue<number>; | |
images: string[]; | |
height: number; | |
width: number; | |
style?: CSSProperties; |
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
function copyStyledText(elementId) { | |
// Step 1: Identify the element | |
const element = document.getElementById(elementId); | |
if (element) { | |
// Step 2: Get the text content | |
const text = element.textContent; | |
// Step 3: Create a temporary element | |
const tempElement = document.createElement('div'); |
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
const handleQueryChange = (updatedQuery) => { | |
setQuery({ ...query, ...updatedQuery }) | |
} | |
const debounceFn = useCallback(_.debounce(handleQueryChange, 500), []); |
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
image: node:18 | |
pipelines: | |
branches: | |
release/prod: | |
- step: | |
deployment: production | |
name: Build and Deploy to Azure Blob Storage | |
caches: | |
- node |
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, { useState } from "react"; | |
import { | |
Flex, | |
Box, | |
Text, | |
IconButton, | |
Icon, | |
SimpleGrid, | |
VStack, | |
} from "@chakra-ui/react"; |
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
<?php | |
// error_reporting(E_ALL); | |
// ini_set('display_errors', 1); | |
set_time_limit(30); // Increase timeout to 30 seconds | |
// Include PHPMailer files manually | |
// Download these from https://github.com/phpmailer/phpmailer/releases version 6.9.3 | |
require '../assets/phpmailer/src/PHPMailer.php'; // Path to the PHPMailer class | |
require '../assets/phpmailer/src/Exception.php'; // Path to the Exception class | |
require '../assets/phpmailer/src/SMTP.php'; // Path to the SMTP class |
OlderNewer