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 dataObject = { | |
firstName: "John", | |
lastName: "Doe", | |
// age // the parse fn will attempt to access this variable which does not exist | |
fullName: "John Doe", | |
}; | |
type DataObjectInput = Record<string, string | number | null>; | |
function parseStringWithTemplateLiteralVariables(rawString = "", variables: DataObjectInput = {}) { |
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
# React Native on M1 | |
Currently, when I scaffold a React Native application using the CLI, I am unable to complete the pod install for iOS. | |
## What I do to solve this? | |
1. After the Pod Install from the CLI fails, `cd` into the `ios` folder. | |
2. Open the terminal in Rosetta. | |
3. Deintegrate Pod. | |
```bash | |
pod deintegrate | |
``` |
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 { useDispatch, useSelector } from "react-redux"; | |
// import { userFetchRefreshedAccessTokenThunk } from redux-thunks-location | |
const App = () => { | |
const dispatch = useDispatch() | |
const { token, tokenExpiresIn, isLoggedIn } = useSelector(reduxAuthUserSlice) | |
// auto refreshing the access token | |
useEffect(() => { |