Selaa lähdekoodia

Created Common Navigation Functions

Savio Fernando 1 vuosi sitten
vanhempi
commit
51a24764ff
1 muutettua tiedostoa jossa 2 lisäystä ja 1 poistoa
  1. 2 1
      src/constants/functions.js

+ 2 - 1
src/constants/functions.js

@@ -106,9 +106,10 @@ export const validateEmail = (email) => {
 
 export const navigateToArticle = (navigation,article_id,article_slug) => {
     navigation.push("NewsDetailPage",{slug: article_slug, id: article_id})
+    navigation.navigate("NewsDetailPage",{slug: article_slug, id: article_id})
   }
 
 
 export const navigateToListViewPage = (navigation,topic_type,topic) => {
-    navigation.navigate("NewsListPage", {type: topic_type, title: topic })
+    navigation.navigate("MainNav",{ screen : "NewsListPage", params :{type: topic_type, title: topic }})
 }