zeba_academy_navigator 1.0.0 copy "zeba_academy_navigator: ^1.0.0" to clipboard
zeba_academy_navigator: ^1.0.0 copied to clipboard

A powerful Flutter navigation toolkit with route management, deep linking, history tracking, custom transitions and route guards.

πŸ“¦ Zeba Academy Navigator

A powerful and lightweight Flutter navigation toolkit built for modern apps.

It provides a clean and scalable navigation system with:

Route management Deep linking support Navigation history tracking Custom transitions Route guards Modular architecture πŸš€ Features 🧭 Global navigation manager (ZebaNavigator) πŸ—ΊοΈ Simple route registration system (ZebaRoute) πŸ”— Deep linking support (zeba://profile/10) πŸ›‘οΈ Route guards for authentication control 🎬 Custom page transitions (fade included) πŸ“œ Navigation history tracking ⚑ Lightweight and dependency-free core 🧩 Easy integration with Flutter apps πŸ“¦ Installation

Add dependency in pubspec.yaml:

dependencies: zeba_academy_navigator: ^1.0.0

Then install:

flutter pub get βš™οΈ Setup

Initialize routes in main.dart:

import 'package:flutter/material.dart'; import 'package:zeba_academy_navigator/zeba_academy_navigator.dart';

void main() { ZebaNavigator.setup( appRoutes: [ ZebaRoute( path: '/home', builder: () => HomePage(), ), ZebaRoute( path: '/profile', builder: () => ProfilePage(), guard: AuthGuard(true), ), ], );

runApp(const MyApp()); }

class MyApp extends StatelessWidget { const MyApp({super.key});

@override Widget build(BuildContext context) { return MaterialApp( navigatorKey: ZebaNavigator.navigatorKey, home: HomePage(), ); } } 🧭 Navigation Usage ➀ Push Route ZebaNavigator.push('/profile'); ➀ Pop Route ZebaNavigator.pop(); ➀ Current Route final route = ZebaNavigator.currentRoute(); πŸ”— Deep Linking final link = ZebaDeepLink("zeba://profile/10");

ZebaNavigator.push(link.path);

Output:

/profile/10 πŸ›‘οΈ Route Guards

Protect routes using custom logic:

class AuthGuard extends ZebaRouteGuard { final bool loggedIn;

AuthGuard(this.loggedIn);

@override Future

Usage:

ZebaRoute( path: '/dashboard', builder: (_) => DashboardPage(), guard: AuthGuard(true), ) 🎬 Custom Transitions

Fade transition example:

ZebaFadeTransition( page: YourPage(), ); πŸ“œ Navigation History print(ZebaNavigator.history); πŸ§ͺ Running Tests flutter test πŸ“ Project Structure lib/ β”œβ”€β”€ src/ β”‚ β”œβ”€β”€ navigator_manager.dart β”‚ β”œβ”€β”€ route_config.dart β”‚ β”œβ”€β”€ route_guard.dart β”‚ β”œβ”€β”€ deep_link.dart β”‚ β”œβ”€β”€ transition.dart └── zeba_academy_navigator.dart πŸ“ˆ Roadmap Nested navigation system Route parameters (/profile/:id) Navigation observers Bottom navigation support Advanced transition builder Web URL synchronization πŸ‘¨β€πŸ’» About Me

✨ I’m Sufyan bin Uzayr, an open-source developer passionate about building and sharing meaningful projects. You can learn more about me at sufyanism.com or connect on LinkedIn

πŸŽ“ Zeba Academy

πŸš€ Explore courses and resources in coding, tech, and development:

🌐 https://zeba.academy πŸ’» https://code.zeba.academy πŸ“Ί https://www.youtube.com/@zeba.academy πŸ“Έ https://www.instagram.com/zeba.academy/ πŸ“„ License

This project is licensed under the GNU General Public License v3.0 (GPL-3.0).

0
likes
140
points
121
downloads

Documentation

API reference

Publisher

verified publisherzeba.academy

Weekly Downloads

A powerful Flutter navigation toolkit with route management, deep linking, history tracking, custom transitions and route guards.

Homepage

License

GPL-3.0 (license)

Dependencies

flutter

More

Packages that depend on zeba_academy_navigator