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 { StyleSheet, View } from 'react-native' | |
import { AreaChart, XAxis, YAxis } from 'react-native-svg-charts' | |
import { Defs, ClipPath, Rect } from 'react-native-svg' | |
export interface ITimeValueChartDatapoint { | |
value: number | |
date: Date | |
} |
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 { PRIMARY, PRIMARY_LIGHT, IRON_GREY } from '@styles/variables/colors' | |
import React, { useEffect, useRef, useState } from 'react' | |
import styled from 'styled-components' | |
const Slider = styled.div` | |
position: relative; | |
margin: 16px auto; | |
width: calc(100% - 12px); | |
height: 8px; | |
background: ${PRIMARY_LIGHT}; |
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 next2PM = new Date(); | |
const offsetHours = next2PM.getTimezoneOffset() / 60; | |
console.log(`current hours at 0 offset (UTC) = ${next2PM.getHours() + offsetHours}h`); | |
next2PM.setHours(14 + offsetHours, 0, 0, 0); // UTC | |
if (new Date() >= next2PM) next2PM.setDate(next2PM.getDate() + 1); // doesn't work for the 30/31st (write a func to calculate the next day) | |
// Update the count down every 1 second | |
const x = setInterval(function () { | |
const now = new Date(); | |
const difference = next2PM.getTime() - now.getTime(); | |
const hours = Math.floor((difference % (1000 * 60 * 60 * 24)) / (1000 * 60 * 60)); // add/remove hours based on timezone |
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 speed = 500; | |
const connectButtons = document.querySelectorAll( | |
'.search-result__actions button[data-control-name="srp_profile_actions"]' | |
); | |
// ==================== INSTRUCTIONS ========================= // | |
// =========================================================== // | |
// 1. Go to LinkedIn Search | |
// 2. Search for People in an industry e.g. CEO |
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 scrape = () => { | |
const showEmail = document.getElementById('P24_ToggleAgentEmailLink') | |
const showNumber = document.getElementById('P24_ToggleAgentNumbersLink') | |
const readMore = document.querySelector('a[title="Read More"]'); | |
let nextClicks = 0 | |
let nextClickInterval = null | |
const showEmailAndThenShowNumber = () => { | |
if (showEmail) showEmail.click() | |
setTimeout(showNumberAndThenReadMore, 3000) | |
} |
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 likeAll = () => { | |
const likes = document.querySelectorAll('.glyphsSpriteHeart__outline__24__grey_9') | |
console.log(`I'm going to like ${likes.length} posts`) | |
likes.forEach(element => { | |
element.click() | |
}) | |
} | |
var scroller = function(by) { | |
window.scrollBy(0, by) |
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 loveAll = () => { | |
document.querySelectorAll('div[aria-label="Comment"] > div > div > div > ul > li > span a').forEach(element => { | |
if (element.innerText === 'Like') { | |
element.addEventListener('mouseover', function() { | |
console.log('Event triggered'); | |
}); | |
const event = new MouseEvent('mouseover', { | |
'view': window, | |
'bubbles': true, |
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
{ | |
"name": "my-sam-package", | |
"version": "1.0.0", | |
"description": "My amazing sam package", | |
"main": "src/index.js", | |
"repository": "https://github.com/my-awesome-org/my-sam-package", | |
"author": "Me", | |
"license": "MIT", | |
"private": true, | |
"scripts": { |
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
NAME=my-sam-package | |
S3_BUCKET=my-sam-package | |
RESOURCES=services | |
ARCHIVE_NAME=resources.zip | |
TEMPLATE_FILE=sam.yaml | |
OUTPUT_TEMPLATE_FILE=sam-output.yaml | |
ENVIRONMENT=production | |
AWS_PROFILE=default | |
REGIONS=( "us-east-1" "us-east-2" "us-west-1" "us-west-2") |
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
NAME=my-sam-package | |
S3_BUCKET=my-sam-package | |
RESOURCES=services | |
ARCHIVE_NAME=resources.zip | |
TEMPLATE_FILE=sam.yaml | |
OUTPUT_TEMPLATE_FILE=sam-output.yaml | |
ENVIRONMENT=production | |
AWS_PROFILE=default | |
REGION=us-east-1 |
NewerOlder