Skip to content

Instantly share code, notes, and snippets.

Avatar
☀️
hablo programación

Przemek Sobstel sobstel

☀️
hablo programación
View GitHub Profile
@sobstel
sobstel / deploy.yml
Created Oct 1, 2020
Deploy Ruby AWS lambda with github action
View deploy.yml
on:
push:
branches:
- "master"
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
View win10vm_apple_keyboard.txt
#NoEnv ; Recommended for performance and compatibility with future AutoHotkey releases.
; #Warn ; Enable warnings to assist with detecting common errors.
SendMode Input ; Recommended for new scripts due to its superior speed and reliability.
SetWorkingDir %A_ScriptDir% ; Ensures a consistent starting directory.
SetScrollLockState, AlwaysOff
;following section remaps alt-delete keys to mimic OSX
;command-delete deletes whole line
;#BS::Send {LShift down}{Home}{LShift Up}{Del}
@sobstel
sobstel / page-speed-report.md
Last active May 7, 2020
Google page speed report 2018
View page-speed-report.md

Google page speed report 2018

  • Time spent on mobile vs desktop 
    • 2015 -> Google started getting more search queries from mobile than desktop
    • 2018 -> Time spent on mobile 2-3x bigger than on desktop (and growing...)
  • Users reaction
    • 46% dislike waiting for slow pages to load 
    • 53% abandon a site that loads in more than 3 seconds
  • As of July 2018, page speed will become an important ranking factor for mobile searches 
    • Page speed will also influence ad rank and the CPC that you pay 
@sobstel
sobstel / createSequentialNavigator.js
Created Apr 29, 2020
React Navigation (v4) sequential navigator
View createSequentialNavigator.js
// @flow
import React, { Component } from 'react';
import _ from 'lodash';
import createStackNavigator from './createStackNavigator';
type Props = {
navigation: *,
};
const DEFAULT_CONFIG = {
@sobstel
sobstel / typescript-cheatsheet.ts
Last active Oct 11, 2019
TypeScript cheatsheet
View typescript-cheatsheet.ts
// same arg type and return type
withUID<T>(obj: T)
// "extends" helps providing some constraints
// eg <T extends object>
withUID({a: 1}) // valid
withUID("wrong way") // NOT valid
// default value type (string)
A<T=string> { name: T }
@sobstel
sobstel / router.rb
Last active Nov 13, 2019
Simple Ruby router
View router.rb
class Router
Route = Struct.new(:pattern, :block)
class RouteSet
def on(pattern, &block)
Router.routes.push Route.new(pattern, block)
end
end
@routes = []
@sobstel
sobstel / no_simulator.txt
Last active Jul 12, 2019
React Native "Could not find iPhone simulator"
View no_simulator.txt
❯ react-native run-ios --simulator="iPhone 7"
Found Xcode workspace Nabobil.xcworkspace
Could not find iPhone 7 simulator
Error: Could not find iPhone 7 simulator
at resolve (...)
sed -i '' 's/startsWith/includes/g' node_modules/react-native/local-cli/runIOS/findMatchingSimulator.js
@sobstel
sobstel / better_conversation.md
Last active Dec 15, 2018
10 ways to have a better conversation (by Celeste Headlee)
View better_conversation.md

10 ways to have a better conversation (by Celeste Headlee)

  1. Don't multitask (be present, be in that moment)
  2. Don't pontificate
  3. Use open-ended questions
  4. Go with the flow
  5. If you don't know, say that you don't know
  6. Don't equate your experience with theirs (it's never the same, all experiences are individual)
  7. Try not to repeat yourself
  8. Stay out of the weeds (people don't care about details)
@sobstel
sobstel / react-native-ios-third-party-build-fix.sh
Created Oct 10, 2018
React Native iOS third-party double-conversion build error fix
View react-native-ios-third-party-build-fix.sh
# error: Build input file cannot be found: '/Users/sobstel/Projects/nabobil/nabobil-mobile/node_modules/react-native/third-party/double-conversion-1.1.6/src/diy-fp.cc'
cd node_modules/react-native/scripts && ./ios-install-third-party.sh && cd ../../../
cd node_modules/react-native/third-party/glog-0.3.5/ && ../../scripts/ios-configure-glog.sh && cd ../../../../
View mvp-cheatsheet.md

MVP cheatsheet

The goal

To prove there is product market fit while taking on the least amount of risk possible.

Steps

1. Define the problem your product solves and what makes your product unique

You can’t perform that action at this time.