mirror of
https://github.com/mudabbir-ahmad/Project-MAD-crudler.git
synced 2026-10-07 20:40:20 +00:00
Prettiered and Logbox ignore log for non-serialized values
This commit is contained in:
1 parent
779913b8b6
commit
d8b40c9d41
3 files changed
+8
-6
No files matched your search
+2
-2
@@ -1,4 +1,4 @@
|
|||||||
import { Pressable, ScrollView, StyleSheet, Text, View } from "react-native";
|
import {Pressable, ScrollView, StyleSheet, Text, View} from "react-native";
|
||||||
|
|
||||||
const Component = () => {
|
const Component = () => {
|
||||||
|
|
||||||
@@ -9,7 +9,7 @@ const Component = () => {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<Text></Text>
|
<Text></Text>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
const styles = StyleSheet.create({});
|
const styles = StyleSheet.create({});
|
||||||
|
|||||||
@@ -3,7 +3,7 @@ import FullWidthImage from "react-native-fullwidth-image";
|
|||||||
import {Button, ButtonTray} from "../../UI/Button";
|
import {Button, ButtonTray} from "../../UI/Button";
|
||||||
import Icons from "../../UI/Icons.js"
|
import Icons from "../../UI/Icons.js"
|
||||||
|
|
||||||
const ModuleView = ({ module, onDelete }) => {
|
const ModuleView = ({module, onDelete}) => {
|
||||||
// Initialisation -------------
|
// Initialisation -------------
|
||||||
// State ----------------------
|
// State ----------------------
|
||||||
// Handlers -------------------
|
// Handlers -------------------
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
import {useState} from "react";
|
import {useState} from "react";
|
||||||
import {StyleSheet} from "react-native";
|
import {LogBox, StyleSheet} from "react-native";
|
||||||
import Screen from "../layout/Screen";
|
import Screen from "../layout/Screen";
|
||||||
import ModuleList from "../entity/modules/ModuleList";
|
import ModuleList from "../entity/modules/ModuleList";
|
||||||
import initialModules from "../../data/modules.js";
|
import initialModules from "../../data/modules.js";
|
||||||
@@ -8,6 +8,7 @@ import RenderCount from "../UI/RenderCount";
|
|||||||
const ModuleListScreen = ({navigation}) => {
|
const ModuleListScreen = ({navigation}) => {
|
||||||
// Initialisation -------------
|
// Initialisation -------------
|
||||||
// let modules = initialModules;
|
// let modules = initialModules;
|
||||||
|
LogBox.ignoreLogs(['Non-serializable values were found in the navigation state']);
|
||||||
|
|
||||||
// State ----------------------
|
// State ----------------------
|
||||||
const [modules, setModules] = useState(initialModules);
|
const [modules, setModules] = useState(initialModules);
|
||||||
@@ -24,12 +25,13 @@ const ModuleListScreen = ({navigation}) => {
|
|||||||
navigation.goBack();
|
navigation.goBack();
|
||||||
}
|
}
|
||||||
|
|
||||||
const handleSelect = (module) => navigation.navigate('ModuleViewScreen', { module, onDelete });
|
const handleSelect = (module) =>
|
||||||
|
navigation.navigate('ModuleViewScreen', {module, onDelete});
|
||||||
// View -----------------------
|
// View -----------------------
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Screen>
|
<Screen>
|
||||||
<RenderCount/>
|
{/*<RenderCount/>*/}
|
||||||
<ModuleList modules={modules} onSelect={handleSelect}/>
|
<ModuleList modules={modules} onSelect={handleSelect}/>
|
||||||
</Screen>
|
</Screen>
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in new issue
Block a user