{"id":21011815,"url":"https://github.com/khellang/caliburn.micro.exposedproperties","last_synced_at":"2025-04-12T08:44:12.128Z","repository":{"id":5465649,"uuid":"6661150","full_name":"khellang/Caliburn.Micro.ExposedProperties","owner":"khellang","description":"A small Caliburn.Micro extension to allow exposing Model properties through a ViewModel with a simple attribute.","archived":false,"fork":false,"pushed_at":"2013-09-11T14:37:29.000Z","size":400,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-06T03:56:33.608Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/khellang.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-11-12T21:45:04.000Z","updated_at":"2019-09-05T09:21:12.000Z","dependencies_parsed_at":"2022-09-25T03:10:45.385Z","dependency_job_id":null,"html_url":"https://github.com/khellang/Caliburn.Micro.ExposedProperties","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/khellang%2FCaliburn.Micro.ExposedProperties","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/khellang%2FCaliburn.Micro.ExposedProperties/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/khellang%2FCaliburn.Micro.ExposedProperties/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/khellang%2FCaliburn.Micro.ExposedProperties/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/khellang","download_url":"https://codeload.github.com/khellang/Caliburn.Micro.ExposedProperties/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248543825,"owners_count":21121837,"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":[],"created_at":"2024-11-19T09:31:24.958Z","updated_at":"2025-04-12T08:44:12.098Z","avatar_url":"https://github.com/khellang.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"Caliburn.Micro.ExposedProperties\n=============================\n\nA small Caliburn.Micro extension that allows you to expose Model properties through a ViewModel with a simple attribute.\n\nUsage\n----------\n\nHook up the property binding to Caliburn.Micro by setting `ViewModelBinder.BindProperties`:\n\n```csharp\nViewModelBinder.BindProperties = ExposedPropertyBinder.BindProperties;\n```\n\t\nDecorate your ViewModel properties with the `ExposeAttribute`:\n\n```csharp\npublic class MyViewModel : PropertyChangedBase\n{\n    private Person _person;\n\n    [Expose(\"FirstName\")]\n    [Expose(\"LastName\")]\n    [Expose(\"ZipCode\")]\n    public Person Person\n    {\n        get { return _person; }\n        set\n        {\n            _person = value;\n            NotifyOfPropertyChange(() =\u003e Person);\n        }\n    }\n}\n\npublic class Person\n{\n    public string FirstName { get; set; }\n\n    public string LastName { get; set; }\n\n    [Expose(\"ZipCode\", \"zip_code\")]\n    public Address Address { get; set; }\n}\n\npublic class Address\n{\n    public string zip_code { get; set; }\n}\n```\n\t\nAnd bind to the new properties:\n\n```xml\n\u003cTextBlock x:Name=\"FirstName\" /\u003e\n\u003cTextBlock x:Name=\"LastName\" /\u003e\n\u003cTextBlock x:Name=\"ZipCode\" /\u003e\n\u003cTextBlock x:Name=\"Person_ZipCode\" /\u003e \u003c!-- ZipCode and Person_ZipCode are the same ;) --\u003e\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkhellang%2Fcaliburn.micro.exposedproperties","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkhellang%2Fcaliburn.micro.exposedproperties","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkhellang%2Fcaliburn.micro.exposedproperties/lists"}