watchman watch-del-all rimraf -r $TMPDIR/react-* rimraf -r node_modules/ rimraf -r build/ios npm cache verify yarn cache clean pc restart yarn install yarn start --reset-cache
This file contains hidden or 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 have multiple npm versions globally in system it causes problem in compilation of projects , make sure you have a stable version in your system --- | |
| *** Multiple npm version conflict issue can occur if you took an update when npm update warning comes in terminal while working *** | |
| note : Use nvm globally to manage node versions in system, if you don't have nvm then install nvm first by following step from this gist https://gist.github.com/RidaRidss/165c2ea31c8de1089e22495f315c7247 | |
| "Open terminal & run commands" | |
| 1. sudo chown -R $(whoami) ~/.npm |
This file contains hidden or 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 (@available(iOS 14, *)) { | |
| UIDatePicker *picker = [UIDatePicker appearance]; | |
| picker.preferredDatePickerStyle = UIDatePickerStyleWheels; | |
| } | |
| Put the above code in AppDelegate.m file, this will override the preferedStyle of any UIDatePicker in the iOS native Workspace |
This file contains hidden or 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/Libraries/Image/RCTUIImageViewAnimated.m. *** Lines 283 to 289 *** | |
| - (void)displayLayer:(CALayer *)layer | |
| { | |
| if (_currentFrame) { | |
| layer.contentsScale = self.animatedImageScale; | |
| layer.contents = (__bridge id)_currentFrame.CGImage; | |
| } | |
| } | |
This file contains hidden or 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
| * npm install nvm -g | |
| * Appending nvm source string to /Users/Rida/.bash_profile | |
| * Appending bash_completion source string to /Users/Rida/.bash_profile | |
| * Close and reopen your terminal to start using nvm or run the following to use it now: | |
| export NVM_DIR="$HOME/.nvm" | |
| [ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm |
This file contains hidden or 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
| export default function createCrudHooks({ | |
| baseKey, | |
| indexFn, | |
| singleFn, | |
| createFn, | |
| updateFn, | |
| deleteFn, | |
| }) { | |
| const useIndex = (config) => useQuery([baseKey], indexFn, config) | |
| const useSingle = (id, config) => |
This file contains hidden or 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
| /* | |
| *** | |
| *** | |
| ** | |
| * | |
| A unique identifier (UID) is an identifier that marks that particular record as unique from every other record. | |
| It allows the record to be referenced in the Summon Index without confusion or unintentional overwriting from other records. | |
| *** | |
| *** | |
| ** |
android/app/build.gradle
--- a/android/app/build.gradle
+++ b/android/app/build.gradle
@@ -80,6 +80,8 @@ import com.android.build.OutputFile
project.ext.react = [
enableHermes: true, // clean and rebuild if changing
+ entryFile: "index.js",
+ bundleAssetName: "app.bundle",
This file contains hidden or 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
| rm -rf $TMPDIR/react-*; rm -rf $TMPDIR/haste-*; rm -rf $TMPDIR/metro-*; watchman watch-del-all; rm -r node_modules/ ; rm -r android/app/build; npm cache verify ; yarn cache clean ; cd ios ; rm -Rf Pods/* && pod cache clean --all && rm -rf ~/Library/Caches/CocoaPods; rm -rf Pods; rm -rf ~/Library/Developer/Xcode/DerivedData/*; pod deintegrate; cd .. && npm install && cd ios; pod install |