{"id":13552174,"url":"https://github.com/aloisdeniel/flutter_device_preview","last_synced_at":"2025-04-09T02:18:24.527Z","repository":{"id":37406065,"uuid":"188779127","full_name":"aloisdeniel/flutter_device_preview","owner":"aloisdeniel","description":"Approximate how your app looks and performs on another device.","archived":false,"fork":false,"pushed_at":"2024-08-05T09:21:33.000Z","size":117022,"stargazers_count":2249,"open_issues_count":126,"forks_count":362,"subscribers_count":19,"default_branch":"master","last_synced_at":"2025-04-02T01:15:38.914Z","etag":null,"topics":["device","flutter","preview","tool"],"latest_commit_sha":null,"homepage":"https://aloisdeniel.github.io/flutter_device_preview/","language":"Dart","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/aloisdeniel.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-05-27T05:51:42.000Z","updated_at":"2025-04-01T15:27:22.000Z","dependencies_parsed_at":"2024-01-15T00:14:15.310Z","dependency_job_id":"aa0838cd-cc77-48ec-b601-a09184df657a","html_url":"https://github.com/aloisdeniel/flutter_device_preview","commit_stats":{"total_commits":182,"total_committers":31,"mean_commits":5.870967741935484,"dds":0.4285714285714286,"last_synced_commit":"9cd7405bee4eb9d52be3633cf0887206a298e6fc"},"previous_names":[],"tags_count":43,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aloisdeniel%2Fflutter_device_preview","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aloisdeniel%2Fflutter_device_preview/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aloisdeniel%2Fflutter_device_preview/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/aloisdeniel%2Fflutter_device_preview/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/aloisdeniel","download_url":"https://codeload.github.com/aloisdeniel/flutter_device_preview/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247962605,"owners_count":21024871,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["device","flutter","preview","tool"],"created_at":"2024-08-01T12:02:00.135Z","updated_at":"2025-04-09T02:18:24.502Z","avatar_url":"https://github.com/aloisdeniel.png","language":"Dart","funding_links":["https://www.buymeacoffee.com/aloisdeniel"],"categories":["Dart"],"sub_categories":[],"readme":"\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://github.com/aloisdeniel/flutter_device_preview/raw/master/logo.png\" alt=\"Device Preview for Flutter\" /\u003e\n\u003c/p\u003e\n\n\u003ch4 align=\"center\"\u003eApproximate how your app looks and performs on another device.\u003c/h4\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"https://pub.dartlang.org/packages/device_preview\"\u003e\u003cimg src=\"https://img.shields.io/pub/v/device_preview.svg\"\u003e\u003c/a\u003e\n  \u003ca href=\"https://www.buymeacoffee.com/aloisdeniel\"\u003e\n    \u003cimg src=\"https://img.shields.io/badge/$-donate-ff69b4.svg?maxAge=2592000\u0026amp;style=flat\"\u003e\n  \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg src=\"https://github.com/aloisdeniel/flutter_device_preview/raw/master/device_preview.gif\" alt=\"Device Preview for Flutter\" /\u003e\n\u003c/p\u003e\n\n## Main features\n\n* Preview any device from any device\n* Change the device orientation\n* Dynamic system configuration (*language, dark mode, text scaling factor, ...)*\n* Freeform device with adjustable resolution and safe areas\n* Keep the application state\n* Plugin system (*Screenshot, File explorer, ...*)\n* Customizable plugins\n\n## Quickstart\n\n### Add dependency to your pubspec file\n\nSince Device Preview is a simple Dart package, you have to declare it as any other dependency in your `pubspec.yaml` file.\n\n```yaml\ndependencies:\n  device_preview: \u003clatest version\u003e\n```\n\n### Add DevicePreview\n\nWrap your app's root widget in a `DevicePreview` and make sure to :\n\n* Set your app's `useInheritedMediaQuery` to `true`.\n* Set your app's `builder` to `DevicePreview.appBuilder`.\n* Set your app's `locale` to `DevicePreview.locale(context)`.\n\n\u003e Make sure to override the previous properties as described. If not defined, `MediaQuery` won't be simulated for the selected device.\n\n```dart\nimport 'package:device_preview/device_preview.dart';\n\nvoid main() =\u003e runApp(\n  DevicePreview(\n    enabled: !kReleaseMode,\n    builder: (context) =\u003e MyApp(), // Wrap your app\n  ),\n);\n\nclass MyApp extends StatelessWidget {\n  @override\n  Widget build(BuildContext context) {\n    return MaterialApp(\n      useInheritedMediaQuery: true,\n      locale: DevicePreview.locale(context),\n      builder: DevicePreview.appBuilder,\n      theme: ThemeData.light(),\n      darkTheme: ThemeData.dark(),\n      home: const HomePage(),\n    );\n  }\n}\n```\n\n## Documentation\n\n\u003ca href='https://aloisdeniel.github.io/flutter_device_preview/' target='_blank'\u003eOpen the website\u003c/a\u003e\n\n## Demo\n\n\u003ca href='https://flutter-device-preview.firebaseapp.com/' target='_blank'\u003eOpen the demo\u003c/a\u003e\n\n## Limitations\n\nThink of Device Preview as a first-order approximation of how your app looks and feels on a mobile device. With Device Mode you don't actually run your code on a mobile device. You simulate the mobile user experience from your laptop, desktop or tablet.\n\n\u003e There are some aspects of mobile devices that Device Preview will never be able to simulate. When in doubt, your best bet is to actually run your app on a real device.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faloisdeniel%2Fflutter_device_preview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Faloisdeniel%2Fflutter_device_preview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Faloisdeniel%2Fflutter_device_preview/lists"}