- Learn how to start a new react native project
- Run it on ios simulator, on android emulator, on a real iPhone device and on a real Android device, with and without debugging enabled.
- Learn how to upgrade a react native project
- Learn how to add a package to the project
- Learn how to add a package that has a native dependency (https://github.com/airbnb/react-native-maps, https://github.com/evollu/react-native-fcm) - DO NOT USE COCOAPODS
- Learn how to use fetch to get data from your backend
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
docker run -p 3307:3306 --name mysql -e MYSQL_ROOT_PASSWORD=root -d mysql:5.7 |
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 { FieldProps } from 'formik' | |
import React from 'react' | |
import Select, { Option, ReactSelectProps } from 'react-select' | |
export const SelectField: React.SFC<ReactSelectProps & FieldProps> = ({ | |
options, | |
field, | |
form, | |
}) => ( | |
<Select |
- Learn how to start a new react native project
- Run it on ios simulator, on android emulator, on a real iPhone device and on a real Android device, with and without debugging enabled.
- Learn how to upgrade a react native project
- Learn how to add a package to the project
- Learn how to add a package that has a native dependency (https://github.com/airbnb/react-native-maps, https://github.com/evollu/react-native-fcm) - DO NOT USE COCOAPODS
- Learn how to use fetch to get data from your backend
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 AuthenticatedHOC = Component => ({ isLoggedIn, ...otherProps }) => | |
isLoggedIn ? <Component {...otherProps}> : <Redirect to="/"> | |
// Component Dashboard | |
// ... | |
// | |
<Router> | |
<Route path="/dashboard" component={AuthenticatedHOC(Dashboard)} /> | |
... |
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
sudo apt-get update && sudo apt-get upgrade -y | |
sudo apt-get install curl git tmux zsh emacs tmux ubuntu-restricted-extras terminator build-essential htop dconf-editor gnome-tweaks tlp tlp-rdw rar unrar -y |
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
img { | |
max-width: 100%; | |
height: auto; | |
} | |
The max-width of 100% will make sure the image is never wider than the container it is in. | |
The height of auto will make the image keep its original aspect ratio. |
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
.sr-only { | |
position: absolute; | |
left: -10000px; | |
width: 1px; | |
height: 1px; | |
top: auto; | |
overflow: hidden; | |
} |
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
If you need to have ncurses first in your PATH run: | |
echo 'export PATH="/usr/local/opt/ncurses/bin:$PATH"' >> ~/.bash_profile | |
For compilers to find ncurses you may need to set: | |
export LDFLAGS="-L/usr/local/opt/ncurses/lib" | |
export CPPFLAGS="-I/usr/local/opt/ncurses/include" |
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
########################### | |
### Configuration | |
############################ | |
# | |
# set Zsh as your default Tmux shell | |
set-option -g default-shell /bin/zsh | |
# use 256 term for pretty colors | |
set -g default-terminal "screen-256color" |
NewerOlder