{"id":13429361,"url":"https://github.com/YoKeyword/Fragmentation","last_synced_at":"2025-03-16T03:31:32.734Z","repository":{"id":37431530,"uuid":"52344952","full_name":"YoKeyword/Fragmentation","owner":"YoKeyword","description":"[DEPRECATED] A powerful library that manage Fragment for Android","archived":false,"fork":false,"pushed_at":"2024-05-30T13:05:05.000Z","size":29343,"stargazers_count":9727,"open_issues_count":191,"forks_count":2114,"subscribers_count":307,"default_branch":"androidx","last_synced_at":"2025-03-11T21:15:27.023Z","etag":null,"topics":["activity-fragment","fragment","swipeback"],"latest_commit_sha":null,"homepage":"","language":"Java","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/YoKeyword.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","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":"2016-02-23T08:54:55.000Z","updated_at":"2025-03-11T12:51:59.000Z","dependencies_parsed_at":"2025-02-11T17:44:04.670Z","dependency_job_id":"84ac30e4-9496-4ce6-a580-af60cdcb97f3","html_url":"https://github.com/YoKeyword/Fragmentation","commit_stats":null,"previous_names":[],"tags_count":37,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YoKeyword%2FFragmentation","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YoKeyword%2FFragmentation/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YoKeyword%2FFragmentation/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/YoKeyword%2FFragmentation/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/YoKeyword","download_url":"https://codeload.github.com/YoKeyword/Fragmentation/tar.gz/refs/heads/androidx","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243822312,"owners_count":20353496,"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":["activity-fragment","fragment","swipeback"],"created_at":"2024-07-31T02:00:35.941Z","updated_at":"2025-03-16T03:31:32.726Z","avatar_url":"https://github.com/YoKeyword.png","language":"Java","funding_links":[],"categories":["UI"],"sub_categories":[],"readme":"[![Android Arsenal](https://img.shields.io/badge/Android%20Arsenal-Fragmentation-brightgreen.svg?style=flat)](https://android-arsenal.com/details/1/5937)\n[![Build Status](https://travis-ci.org/YoKeyword/Fragmentation.svg?branch=master)](https://travis-ci.org/YoKeyword/Fragmentation)\n[![Download](https://api.bintray.com/packages/yokeyword/maven/Fragmentation/images/download.svg) ](https://bintray.com/yokeyword/maven/Fragmentation/_latestVersion)\n[![Hex.pm](https://img.shields.io/hexpm/l/plug.svg)](https://www.apache.org/licenses/LICENSE-2.0)\n\n# PLEASE NOTE, THIS PROJECT IS NO LONGER BEING MAINTAINED\n****\n### [中文版 README.md](https://github.com/YoKeyword/Fragmentation/blob/master/README_CN.md)\n\n# FragmentationX\n\n![](/gif/logo.png)\n\nFragmentation is a powerful library managing Fragment for Android.\n\nIt is designed for \"Single Activity + Multi-Fragments\" and \"Multi-FragmentActivities + Multi-Fragments\" architecture to simplify development process.\n\n## Demo\nThe first demo shows the basic usage of the library. The second one shows the way to implement an app which is similar to Instagram. Complicated nested fragments' usage demo are also showed.\n\n## [Download APK](https://www.pgyer.com/fragmentation)\n\n\u003cimg src=\"/gif/demo1.gif\" width=\"280px\"/\u003e \u003cimg src=\"/gif/demo2.gif\" width=\"280px\"/\u003e\n \u003cimg src=\"/gif/demo3.gif\" width=\"280px\"/\u003e\n\n## Feature\n\n**1. Develop complicated nested fragment app rapidly**\n\n**2. Use fragment's stack view dialog to debug easily**\n\n**3. Add launch mode, startForResult etc. to provide similar behavior of Activity**\n\n**4. Add onBackPressedSupport() method to support back button press monitoring in Fragment**\n\n**5. Add onSupportVisible(), onLazyInitView() to simplify dev**\n\n**6. Easily manage Fragment transition animations**\n\n**7. To simplify the communication between Fragment([EventBusActivityScope module](https://github.com/YoKeyword/Fragmentation/blob/master/eventbus_activity_scope/README.md))**\n\n**8. Support SwipeBack to pop(Fragmentation_SwipeBack module [README](https://github.com/YoKeyword/Fragmentation/blob/master/fragmentation_swipeback/README.md))**\n\n\u003cimg src=\"/gif/stack.png\" width=\"150px\"/\u003e \u003cimg src=\"/gif/log.png\" width=\"300px\"/\u003e       \u003cimg src=\"/gif/SwipeBack.png\" width=\"150px\"/\u003e\n\n## How do I use Fragmentation?\n### Note: This is the use of androidx, if you are using the android.support, [click here `branch:master`](https://github.com/YoKeyword/Fragmentation/blob/master/README.md)\n**1、build.gradle**\n````gradle\n// This is the use of androidx, if you are using the android.support: fragmentationx -\u003e fragmentation\nimplementation 'me.yokeyword:fragmentationx:1.0.2'\n\n// If you don't want to extends SupportActivity/Fragment and would like to customize your own support, just rely on fragmentation-core\n// implementation 'me.yokeyword:fragmentationx-core:1.0.2'\n\n// To get SwipeBack feature, rely on both fragmentation \u0026 fragmentation-swipeback\nimplementation 'me.yokeyword:fragmentationx:1.0.2'\n// Swipeback is based on fragmentation. Refer to SwipeBackActivity/Fragment for your Customized SupportActivity/Fragment\nimplementation 'me.yokeyword:fragmentationx-swipeback:1.0.2'\n\n// To simplify the communication between Fragments.\nimplementation 'me.yokeyword:eventbus-activity-scope:1.1.0'\n// Your EventBus's version\nimplementation 'org.greenrobot:eventbus:{version}'\n````\n\n**2. Activity `extends` SupportActivity or `implements` ISupportActivity：(refer to [MySupportActivity](https://github.com/YoKeyword/Fragmentation/blob/master/demo/src/main/java/me/yokeyword/sample/demo_flow/base/MySupportActivity.java))**\n````java\n// since v1.0.0, forced extends of SupportActivity is not required, you can use interface + delegate to implement your own SupportActivity \npublic class MainActivity extends SupportActivity {\n\n    @Override\n    protected void onCreate(Bundle savedInstanceState) {\n        super.onCreate(savedInstanceState);\n        setContentView(...);\n      \t// Fragmentation is recommended to initialize in the Application\n        Fragmentation.builder()\n          \t // show stack view. Mode: BUBBLE, SHAKE, NONE\n             .stackViewMode(Fragmentation.BUBBLE)\n             .debug(BuildConfig.DEBUG)\n             ...\n             .install();\n\n        if (findFragment(HomeFragment.class) == null) {\n            loadRootFragment(R.id.fl_container, HomeFragment.newInstance());  //load root Fragment\n        }\n    }\n````\n\n**3. Fragment `extends` SupportFragment or `implements` ISupportFragment：(refer to [MySupportFragment](https://github.com/YoKeyword/Fragmentation/blob/master/demo/src/main/java/me/yokeyword/sample/demo_flow/base/MySupportFragment.java))：**\n````java\n// since v1.0.0, forced extends of SupportActivity is not required, you can use interface + delegate to implement your own SupportActivity\npublic class HomeFragment extends SupportFragment {\n\n    private void xxx() {\n      \t// launch a new Fragment, other methods: start(fragment,SINGTASK)、startForResult、startWithPop etc.\n        start(DetailFragment.newInstance(HomeBean));\n      \t// check wiki for other pop, find and animation setting related API\n    }\n}\n````\n\n## [WIKI](https://github.com/YoKeyword/Fragmentation/wiki) , [CHANGELOG](https://github.com/YoKeyword/Fragmentation/blob/master/CHANGELOG.md)\n\n## LICENSE\n````\nCopyright 2016 YoKey\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n````\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FYoKeyword%2FFragmentation","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FYoKeyword%2FFragmentation","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FYoKeyword%2FFragmentation/lists"}