{"id":13710934,"url":"https://github.com/Pepsi1x1/XamarinForms.VisualDebug","last_synced_at":"2025-05-06T20:31:20.533Z","repository":{"id":37185293,"uuid":"295468974","full_name":"Pepsi1x1/XamarinForms.VisualDebug","owner":"Pepsi1x1","description":"A library and client app to view the visual heirarchy of your Xamarin app pages as an interactive tree diagram at runtime","archived":false,"fork":false,"pushed_at":"2023-01-06T14:51:03.000Z","size":3119,"stargazers_count":22,"open_issues_count":19,"forks_count":1,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-11-04T23:07:06.874Z","etag":null,"topics":["electron","electron-app","xamarin","xamarin-forms","xamarin-library","xamarinforms"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","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/Pepsi1x1.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-09-14T16:06:24.000Z","updated_at":"2022-02-23T21:12:56.000Z","dependencies_parsed_at":"2023-02-06T05:31:03.633Z","dependency_job_id":null,"html_url":"https://github.com/Pepsi1x1/XamarinForms.VisualDebug","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Pepsi1x1%2FXamarinForms.VisualDebug","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Pepsi1x1%2FXamarinForms.VisualDebug/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Pepsi1x1%2FXamarinForms.VisualDebug/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Pepsi1x1%2FXamarinForms.VisualDebug/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Pepsi1x1","download_url":"https://codeload.github.com/Pepsi1x1/XamarinForms.VisualDebug/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224528287,"owners_count":17326330,"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":["electron","electron-app","xamarin","xamarin-forms","xamarin-library","xamarinforms"],"created_at":"2024-08-02T23:01:02.394Z","updated_at":"2024-11-13T21:31:16.051Z","avatar_url":"https://github.com/Pepsi1x1.png","language":"JavaScript","readme":"# XamarinForms.VisualDebugger\n\nA library and client app to view the visual heirarchy of your Xamarin app pages as an interactive tree diagram at runtime\n\n![Preview](https://github.com/Pepsi1x1/XamarinForms.VisualDebug/raw/master/final-5f6f58c13e5b3e0061bb6cf9-6.gif \"Preview\")\n\n# Getting Started\n\nInstall the XamarinForms.VisualDebug Nuget packages into your Core AND platform specific projects\n\n```sh\nInstall-Package XamarinForms.VisualDebug\ndotnet add package XamarinForms.VisualDebug\n```\n\n## Core project\n\nFor the simplest use case in App.xaml.cs include the following\n\n```c#\n       public App()\n        {\n            InitializeComponent();\n\n            MainPage = new NavigationPage(new MainPage());\n\n            //Add this line\n            Current.PageAppearing += Current_PageAppearing;\n        }\n\n        private void Current_PageAppearing(object sender, Page e)\n        {\n            XamarinForms.VisualDebug.Core.Utility.RenderAndSend(e);\n        }\n```\n\nTo use the iOS simulator, the Xamarin app needs to know the IP address of the computer running the client app, wither provide that as the second argument to Sender.SendToServer manually, or there is a helper you can include in your core project which tries to work out the IP at compile time:\n\nhttps://github.com/Pepsi1x1/XamarinForms.VisualDebug/blob/master/XamarinForms.VisualDebug/XamarinForms.VisualDebug/IPConstant.tt\n\nand the following snippet consumes that:\n\n```c#\n                string ip = string.Empty;\n                // Only needed on iOS, a null or empty string passed in uses the platform default for android internally 10.0.2.2 or 127.0.0.1 on other platforms\n                if (Xamarin.Forms.Device.RuntimePlatform == Xamarin.Forms.Device.iOS)\n                {\n                    ip = XamarinForms.VisualDebug.Constants.IPConstant.LocalIP;\n                }\n\n                XamarinForms.VisualDebug.Core.Utility.RenderAndSend(e, ip);\n```\n\n## iOS\n\nAdd the following line to FinishedLaunching in AppDelegate.cs somehwher after the Xamarin.Forms.Forms.Init call\n\n```c#\n            XamarinForms.VisualDebug.iOS.VisualDebug.Init();\n```       \n            \n## Android\n\nAdd the following line to FinishedLaunching in AppDelegate.cs somehwher after the Xamarin.Forms.Forms.Init call\n\n```c#\n            XamarinForms.VisualDebug.Droid.VisualDebug.Init();\n```\n            \n## Electron app\n\nRun the client before starting the simluator/emulator for your Xamarin app\n\n```sh\n$ cd XamarinForms.VisualDebug.App\n# Install dependencies\n$ npm install\n# Run the app\n$ npm start     \n```\n","funding_links":[],"categories":["Tools"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FPepsi1x1%2FXamarinForms.VisualDebug","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FPepsi1x1%2FXamarinForms.VisualDebug","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FPepsi1x1%2FXamarinForms.VisualDebug/lists"}