{"id":13420038,"url":"https://github.com/facebook/yoga","last_synced_at":"2025-09-09T19:53:34.209Z","repository":{"id":15764866,"uuid":"18503721","full_name":"facebook/yoga","owner":"facebook","description":"Yoga is an embeddable layout engine targeting web standards.","archived":false,"fork":false,"pushed_at":"2025-03-24T19:26:57.000Z","size":26599,"stargazers_count":17674,"open_issues_count":116,"forks_count":1464,"subscribers_count":388,"default_branch":"main","last_synced_at":"2025-05-05T14:13:13.649Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://yogalayout.dev/","language":"C++","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/facebook.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","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,"zenodo":null}},"created_at":"2014-04-07T01:37:37.000Z","updated_at":"2025-05-05T11:30:01.000Z","dependencies_parsed_at":"2024-01-23T00:39:50.329Z","dependency_job_id":"eccc0343-eaaa-4c13-b4af-4b5eb39b9445","html_url":"https://github.com/facebook/yoga","commit_stats":{"total_commits":2427,"total_committers":314,"mean_commits":7.729299363057325,"dds":0.8590852904820766,"last_synced_commit":"6212e561ad09012a8682406590609d87e75e218b"},"previous_names":["facebook/css-layout"],"tags_count":59,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/facebook%2Fyoga","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/facebook%2Fyoga/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/facebook%2Fyoga/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/facebook%2Fyoga/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/facebook","download_url":"https://codeload.github.com/facebook/yoga/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253342299,"owners_count":21893558,"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-07-30T22:01:25.024Z","updated_at":"2025-05-12T16:16:45.660Z","avatar_url":"https://github.com/facebook.png","language":"C++","readme":"# Yoga [![CocoaPods](https://img.shields.io/cocoapods/v/Yoga.svg)](http://cocoapods.org/pods/Yoga) [![npm](https://img.shields.io/npm/v/yoga-layout.svg)](https://www.npmjs.com/package/yoga-layout) [![Maven Central](https://img.shields.io/maven-central/v/com.facebook.yoga/yoga)](https://search.maven.org/artifact/com.facebook.yoga/yoga) ![SPM](https://img.shields.io/badge/SPM-Supported-blue.svg)\n\nYoga is an embeddable and performant flexbox layout engine with bindings for multiple languages.\n\n## Building\n\nYoga's main implementation targets C++ 20 with accompanying build logic in CMake. A wrapper is provided to build the main library and run unit tests.\n\n```sh\n./unit_tests \u003cDebug|Release\u003e\n```\n\nWhile not required, this script will use [ninja](https://ninja-build.org/) if it is installed for faster builds.\n\nYoga is additionally part of the [vcpkg](https://github.com/Microsoft/vcpkg/) collection of ports maintained by Microsoft and community contributors. If the version is out of date, please [create an issue or pull request](https://github.com/Microsoft/vcpkg) on the vcpkg repository.\n\n## Adding Tests\n\nMany of Yoga's tests are automatically generated, using HTML fixtures describing node structure. These are rendered in Chrome to generate an expected layout result for the tree. New fixtures can be added to `gentest/fixtures`.\n\n```html\n\u003cdiv id=\"my_test\" style=\"width: 100px; height: 100px; align-items: center;\"\u003e\n  \u003cdiv style=\"width: 50px; height: 50px;\"\u003e\u003c/div\u003e\n\u003c/div\u003e\n```\n\nTo generate new tests from added fixtures:\n\n1. Ensure you have [yarn classic](https://classic.yarnpkg.com) installed.\n2. Run `yarn install` to install dependencies for the test generator.\n3. Run `yarn gentest` in the `yoga` directory.\n\n## Debugging\n\nYoga provides a VSCode \"launch.json\" configuration which allows debugging unit tests. Simply add your breakpoints, and run \"Debug C++ Unit tests (lldb)\" (or \"Debug C++ Unit tests (vsdbg)\" on Windows).\n","funding_links":[],"categories":["TODO scan for Android support in followings","C++","GUI Frameworks","Layout Engines","UI Frameworks","Uncategorized","Major","Libraries","Graphic Layout Engine"],"sub_categories":["Flexbox","Uncategorized","UI","C++","Rust 2D renderer"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffacebook%2Fyoga","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ffacebook%2Fyoga","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ffacebook%2Fyoga/lists"}