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 requests | |
from bs4 import BeautifulSoup | |
from bs4.element import Comment | |
def tag_visible(element): | |
""" | |
Determines if a tag is visible based on its parent's name and whether it is a comment. | |
Parameters: | |
element: The BeautifulSoup element to check visibility for. |
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, { useEffect, useState } from "react"; | |
import { Dimensions, SafeAreaView, StyleSheet, Text, View } from "react-native"; | |
import { | |
PanGestureHandler, | |
TouchableOpacity, | |
ScrollView, | |
} from "react-native-gesture-handler"; | |
import Animated, { | |
useAnimatedGestureHandler, | |
useAnimatedStyle, |
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
#!/bin/bash | |
# install brew if not installed | |
if [[ $(command -v brew) == "" ]]; then | |
echo "Installing Hombrew" | |
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" | |
fi | |
# check if wget is installed | |
if brew ls --versions myformula > /dev/null; then |
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
# Represents a dictionary as an instance (note: cannot yet cast bact to dict type, simple access <InstanceDict>.d | |
class InstanceDict: | |
def __init__(self, d): | |
self.d = d | |
def __getattribute__(self, item): | |
return self.__getattr__(item) | |
def __getattr__(self, key): | |
val = self.d[key] |