Skip to content

Instantly share code, notes, and snippets.

View alperkilickaya's full-sized avatar
🧑‍💻
Solving problems

Alper Kilickaya alperkilickaya

🧑‍💻
Solving problems
View GitHub Profile
function App () {
const dispatch = useDispatch();
const [currentVideo, setVideo] = useState(null);
const videoList = useSelector(state => state.app.videoList);
const queue = useSelector(state => state.app.queue);
useEffect(() => {
dispatch(getVideosApi());
dispatch(uploadNext(true));
}, []);
import { createStore, applyMiddleware, combineReducers } from 'redux';
import thunkMiddleware from 'redux-thunk';
import { ProcessingManager } from 'react-native-video-processing';
import storage from '@react-native-firebase/storage';
import * as mockApi from './mock-api';
const ADD_QUEUE_QUEUE = 'ADD_QUEUE_QUEUE';
const SET_CURRENT_STATE = 'SET_CURRENT_STATE';
const REMOVE_FROM_QUEUE = 'REMOVE_FROM_QUEUE';
const SET_VIDEO_LIST = 'SET_VIDEO_LIST';
//...
export default function SelectFile () {
const dispatch = useDispatch();
const pickVideo = () => {
const options = {
title: 'Upload Video',
takePhotoButtonTitle: 'Record video',
chooseFromLibraryButtonTitle: 'Choose From Library',
mediaType: 'video',
@wojteklu
wojteklu / clean_code.md
Last active December 9, 2025 17:42
Summary of 'Clean code' by Robert C. Martin

Code is clean if it can be understood easily – by everyone on the team. Clean code can be read and enhanced by a developer other than its original author. With understandability comes readability, changeability, extensibility and maintainability.


General rules

  1. Follow standard conventions.
  2. Keep it simple stupid. Simpler is always better. Reduce complexity as much as possible.
  3. Boy scout rule. Leave the campground cleaner than you found it.
  4. Always find root cause. Always look for the root cause of a problem.

Design rules