Enjoy ! 😄
Download iTerm2 here.
| /* Copyright 2019 The Android Open Source Project | |
| * | |
| * Licensed under the Apache License, Version 2.0 (the "License"); | |
| * you may not use this file except in compliance with the License. | |
| * You may obtain a copy of the License at | |
| * | |
| * https://www.apache.org/licenses/LICENSE-2.0 | |
| * | |
| * Unless required by applicable law or agreed to in writing, software | |
| * distributed under the License is distributed on an "AS IS" BASIS, |
Enjoy ! 😄
Download iTerm2 here.
| ffmpeg -i "c:/videos/sample.mp4 | |
| -map 0:v:0 -map 0:a:0 -map 0:v:0 -map 0:a:0 -map 0:v:0 -map 0:a:0 | |
| -c:v libx264 -crf 22 -c:a aac -ar 48000 | |
| -filter:v:0 scale=w=480:h=360 -maxrate:v:0 600k -b:a:0 64k | |
| -filter:v:1 scale=w=640:h=480 -maxrate:v:1 900k -b:a:1 128k | |
| -filter:v:2 scale=w=1280:h=720 -maxrate:v:2 900k -b:a:2 128k | |
| -var_stream_map "v:0,a:0,name:360p v:1,a:1,name:480p v:2,a:2,name:720p" | |
| -preset slow -hls_list_size 0 -threads 0 -f hls -hls_playlist_type event -hls_time 3 | |
| -hls_flags independent_segments -master_pl_name "name-pl.m3u8" | |
| "c:/videos/encoded/name-%v.m3u8" |
| struct ScreenSize { | |
| static let width = UIScreen.main.bounds.size.width | |
| static let height = UIScreen.main.bounds.size.height | |
| static let maxLength = max(ScreenSize.width, ScreenSize.height) //Gets the Height | |
| static let minLength = min(ScreenSize.width, ScreenSize.height) //Gets the Width | |
| } | |
| //Contains the dimensions of the devices | |
| fileprivate struct KeybDimensions{ | |
| //iPod touch(7), iPhone 5, iPhone 5s, iPhone 5C, iPhone SE |
| import React from "react"; | |
| import { Dimensions, StyleSheet, Text, View } from "react-native"; | |
| import { PanGestureHandler } from "react-native-gesture-handler"; | |
| import Animated, { | |
| Easing, | |
| Extrapolate, | |
| interpolate, | |
| useAnimatedGestureHandler, | |
| useAnimatedReaction, | |
| useAnimatedStyle, |
| import { View, StyleSheet, TouchableWithoutFeedback } from 'react-native'; | |
| import React from 'react'; | |
| import Animated, { useSharedValue, withRepeat, useAnimatedStyle, withTiming } from 'react-native-reanimated' | |
| const App: () => React$Node = () => { | |
| const animation = useSharedValue(1) | |
| const animationStyle = useAnimatedStyle(() => { | |
| return { | |
| transform: [ |
| import { createContext, forwardRef, useCallback, useMemo } from "react"; | |
| import { FlatList, FlatListProps, ViewToken } from "react-native"; | |
| import Animated, { useSharedValue } from "react-native-reanimated"; | |
| const MAX_VIEWABLE_ITEMS = 4; | |
| type ViewabilityItemsContextType = string[]; | |
| export const ViewabilityItemsContext = createContext< | |
| Animated.SharedValue<ViewabilityItemsContextType> |
| const { withDangerousMod, withPlugins } = require("@expo/config-plugins"); | |
| const { | |
| mergeContents, | |
| } = require("@expo/config-plugins/build/utils/generateCode"); | |
| const fs = require("fs"); | |
| const path = require("path"); | |
| async function readFileAsync(path) { | |
| return fs.promises.readFile(path, "utf8"); | |
| } |
If you ever need to modify the proguard rules for the Android-part of your Expo managed workflow, you can achieve this by using a config plugin.
./plugins in the project root folder.withProguardRules.js and my-proguard-rules.pro in the folderplugins array of your app.config.js (or app.json if you're using that instead).NOTE: if you rename your .pro file, don't forget to change the two occurrences of my-proguard-rules in withProguardRules.js as well.
| import android.annotation.SuppressLint; | |
| import android.annotation.TargetApi; | |
| import android.app.AppOpsManager; | |
| import android.content.Context; | |
| import android.content.Intent; | |
| import android.text.TextUtils; | |
| import java.lang.reflect.Method; | |
| // MIUI. Redefining Android. |