{"id":15633908,"url":"https://github.com/guidomb/portalview","last_synced_at":"2025-10-10T02:33:07.167Z","repository":{"id":147507016,"uuid":"82432198","full_name":"guidomb/PortalView","owner":"guidomb","description":"A (potentially) cross-platform, declarative and immutable Swift library for building user interfaces","archived":false,"fork":false,"pushed_at":"2017-05-12T18:54:34.000Z","size":181,"stargazers_count":15,"open_issues_count":0,"forks_count":2,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-30T04:49:59.163Z","etag":null,"topics":["declarative-ui","immutable","swift","ui"],"latest_commit_sha":null,"homepage":null,"language":"Swift","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/guidomb.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":"2017-02-19T03:20:19.000Z","updated_at":"2018-03-13T19:01:43.000Z","dependencies_parsed_at":null,"dependency_job_id":"79504fef-9e60-4682-b7ac-efeda03357f4","html_url":"https://github.com/guidomb/PortalView","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/guidomb/PortalView","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guidomb%2FPortalView","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guidomb%2FPortalView/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guidomb%2FPortalView/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guidomb%2FPortalView/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/guidomb","download_url":"https://codeload.github.com/guidomb/PortalView/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/guidomb%2FPortalView/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":279002538,"owners_count":26083400,"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","status":"online","status_checked_at":"2025-10-10T02:00:06.843Z","response_time":62,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["declarative-ui","immutable","swift","ui"],"created_at":"2024-10-03T10:50:35.849Z","updated_at":"2025-10-10T02:33:07.152Z","avatar_url":"https://github.com/guidomb.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"PortalView\n==========\n\n[![Swift](https://img.shields.io/badge/swift-3-orange.svg?style=flat)](#)\n[![Carthage compatible](https://img.shields.io/badge/Carthage-compatible-4BC51D.svg?style=flat)](https://github.com/Carthage/Carthage)\n[![Platform](https://img.shields.io/badge/platform-iOS-lightgrey.svg?style=flat)](#)\n[![License](https://img.shields.io/badge/license-MIT-blue.svg?style=flat)](https://opensource.org/licenses/MIT)\n\nA (potentially) cross-platform, declarative and immutable Swift library for building user interfaces.\n\n**WARNING!: This is still a work-in-progress, although the minimum features are available to create real world applications the API is still under design and some key optimizations are still missing. Use at your own risk.**\n\n## TL; DR;\n\n * Declarative API inspired by [Elm](http://elm-lang.org/) and [React](https://facebook.github.io/react/).\n * 100% in Swift and decoupled from UIKit which makes it (potentially) cross-platform.\n * Uses facebook's [Yoga](http://github.com/facebook/yoga). A cross-platform layout engine that implements [Flexbox](https://www.w3schools.com/CSS/css3_flexbox.asp) which is used by [ReactNative](https://github.com/facebook/react-native).\n * Leverage the Swift compiler in order to have a strongly type-safe API.\n\nHere is a sneak peak of the API but you can also check [this examples](https://github.com/guidomb/PortalView#example) or read the library [overview](./Documentation/Overview.md) to learn more about the main concepts.\n\n```swift\nenum Message {\n\n  case like\n  case goToDetailScreen\n\n}\n\nlet component: Component\u003cMessage\u003e = container(\n  children: [\n    label(\n      text: \"Hello PortalView!\",\n      style: labelStyleSheet() { base, label in\n          base.backgroundColor = .white\n          label.textColor = .red\n          label.textSize = 12\n      },\n      layout: layout() {\n          $0.flex = flex() {\n              $0.grow = .one\n          }\n          $0.justifyContent = .flexEnd\n      }\n    )\n    button(\n      properties: properties() {\n          $0.text = \"Tap to like!\"\n          $0.onTap = .like\n      }\n    )\n    button(\n      properties: properties() {\n          $0.text = \"Tap to got to detail screen\"\n          $0.onTap = .goToDetailScreen\n      }\n    )\n  ]\n)\n```\n\n## Installation\n\n### Carthage\n\nInstall [Carthage](https://github.com/Carthage/Carthage) first by either using the [official .pkg installer](https://github.com/Carthage/Carthage/releases) for the latest release or If you use [Homebrew](http://brew.sh) execute the following commands:\n\n```\nbrew update\nbrew install carthage\n```\n\nOnce Carthage is installed add the following entry to your `Cartfile`\n\n```\ngithub \"guidomb/PortalView\" \"master\"\n```\n\n### Manual\n\nTODO\n\n## Example\n\nFor some examples on how the API looks like and how to use this library check\n\n * The [examples](./Examples.xcodeproj) project in this repository.\n * [This](https://github.com/guidomb/SyrmoPortalExample) example project\n * The following video\n\n[![PortalView live reload example](https://img.youtube.com/vi/Xaj6vdNLC5k/0.jpg)](https://www.youtube.com/watch?v=Xaj6vdNLC5k)\n\n## Documentation\n\nPortalView is still a work-in-progress. Documentation will be added as the library matures inside the [Documentation](./Documentation) directory.\nYou can read the library [overview](./Documentation/Overview.md) to learn more about the main concepts.\n\n## Contribute\n\n### Setup\n\nInstall [Carthage](https://github.com/Carthage/Carthage) first, then run\n\n```\ngit clone git@github.com:guidomb/PortalView.git\ncd PortalView\nscript/bootstrap\nopen PortalView.xcworkspace\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fguidomb%2Fportalview","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fguidomb%2Fportalview","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fguidomb%2Fportalview/lists"}