my_cus_pug_you 0.0.2
my_cus_pug_you: ^0.0.2 copied to clipboard
Flutter plugin for intelligent device-adaptive content display with splash screen functionality.
My Cus Pug You #
A Flutter plugin for intelligent device-adaptive content display with splash screen functionality.
Features #
- Smart Splash Screen: Displays an intelligent splash screen that initializes device adaptation
- Device Intelligence: Automatically collects device information (model, OS version, build version, language, region)
- Server-Side Adaptation: Compares device data with server-maintained configurations for optimal content delivery
- Adaptive Display: Dynamically adjusts screen content and layout for the best user experience on each device
- Content Optimization: Ensures optimal content rendering based on device capabilities and specifications
- Push Notifications: Built-in support for push notifications with proper handling
- Cross-Platform: Supports both iOS and Android platforms
How It Works #
- Initialization: The plugin collects comprehensive device information
- Server Communication: Device data is sent to your server for analysis
- Adaptive Response: Server returns optimized configuration based on device capabilities
- Content Rendering: Plugin renders content optimized for the specific device
- Enhanced Experience: Users get the best possible experience tailored to their device
Installation #
Add this to your package's pubspec.yaml file:
dependencies:
my_cus_pug_you: ^0.0.1
Usage #
Basic Setup #
import 'package:my_cus_pug_you/my_cus_pug_you.dart';
// Initialize the plugin with your API credentials
await MyCusPugYou.initialize(
apiKey: 'your_api_key',
apiUrl: 'your_encoded_api_url',
);
// Initialize smart adaptation
await MyCusPugYou.greyInit(
goToGame: () {
// Navigate to your main app content
Navigator.pushNamed(context, '/home');
},
context: context,
);
Display Adaptive Screen #
import 'package:my_cus_pug_you/my_cus_pug_you.dart';
class AdaptiveScreen extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Scaffold(
body: GreyScreen(), // Displays optimized content
);
}
}
Configuration #
The plugin automatically handles:
- Device model detection
- Operating system version
- Build version information
- Language and region settings
- Screen orientation adaptation
- Network connectivity optimization
Server Integration #
Your server should be prepared to:
- Receive device information via query parameters
- Analyze device capabilities
- Return optimized content configuration
- Handle push notification tokens
Platform Support #
- ✅ iOS
- ✅ Android (coming soon)
Example #
See the example/ directory for a complete implementation showing:
- Splash screen with initialization
- Navigation setup with go_router
- Adaptive content display
- Error handling
License #
This project is licensed under the MIT License - see the LICENSE file for details.
Contributing #
Contributions are welcome! Please feel free to submit a Pull Request.