Invalid props provided to navigation action at Object.executeAction

24 views Asked by At

I am working on BlueBase Framework which is based on React and React-Native. I have Followed Documentation on BlueBase Documentation. I am facing such an issue while adding New Task to my app.

enter image description here

import { createPlugin } from '@bluebase/core';
import { ToDoAppIcon } from './components/ToDoAppIcon';
import { PendingTasksScreen } from './screens/PendingTasksScreen';
import { EditTaskScreen} from "./screens/EditTaskScreen";
import { routes } from './routes';

export default createPlugin({
     key: 'tasks',
     name: 'Tasks',
     description: 'A todo app made with BlueBase framework.',

     // ... Other plugin properties

     indexRoute: 'TasksApp',

     components: {
         // Components
         ToDoAppIcon,

         // Screens
         PendingTasksScreen,
         EditTaskScreen,
     },

     icon: {
         component: 'ToDoAppIcon',
         type: 'component',
     },

     indexRoute: 'TasksApp',

     routes,
 });
1

There are 1 answers

0
Talha On BEST ANSWER

You need to Import CreateTaskScreen and also add this under components object.

Also, you can replace your code with

import { createPlugin } from '@bluebase/core';
import { ToDoAppIcon } from './components/ToDoAppIcon';
import { PendingTasksScreen } from './screens/PendingTasksScreen';
import { EditTaskScreen} from "./screens/EditTaskScreen";
import { CreateTaskScreen} from "./screens/CreateTaskScreen";
import { routes } from './routes';

export default createPlugin({
    key: 'tasks',
    name: 'Tasks',
    description: 'A todo app made with BlueBase framework.',

    // ... Other plugin properties

    indexRoute: 'TasksApp',

    components: {
        // Components
        ToDoAppIcon,

        // Screens
        PendingTasksScreen,
        EditTaskScreen,
        CreateTaskScreen
    },

    icon: {
        component: 'ToDoAppIcon',
        type: 'component',
    },

    indexRoute: 'TasksApp',

    routes,
});

I hope this will help you.