当前位置: 首页 > 软件库 > 手机/移动开发 > >

compose-samples

Official Jetpack Compose samples.
授权协议 Apache-2.0 License
开发语言 Java
所属分类 手机/移动开发
软件类型 开源软件
地区 不详
投 递 者 史洛城
操作系统 跨平台
开源组织
适用人群 未知
 软件概览

Jetpack Compose Samples

This repository contains a set of individual Android Studio projects to help you learn aboutCompose in Android. Each sample demonstrates different use cases, complexity levels and APIs.

For more information, please read the documentation

�� Requirements

To try out these sample apps, you need to use Android Studio Arctic Fox.You can clone this repository or import theproject from Android Studio following the stepshere.

�� Samples

Project



A sample blog post viewer that demonstrates the use of Compose with a typical Material app and real-world architecture.

• Medium complexity
• Varied UI
• Light & dark themes
• Resource loading
• UI Testing

> Browse




A sample chat app that focuses on UI state patterns and text input.

• Low complexity
• Simple Material Design theme (Light & dark)
• Resource loading
• Back button handling
• Integration with Architecture Components: Navigation, Fragments, LiveData, ViewModel
• Animation
• UI Testing

> Browse




A sample survey app that showcases text input, validation and UI state management in Compose.

• Low complexity
TextField and form validation
• Snackbar implementation
• Element reusability and styling
• Various form elements


> Browse




Jetsnack is a sample snack ordering app built with Compose.

• Medium complexity
• Custom design system
• Custom layouts
• Animation

> Browse




A sample podcast app that features a full-featured, Redux-style architecture and showcases dynamic themes.

• Advanced sample
• Dynamic theming using podcast artwork
• Image fetching
WindowInsets support
• Coroutines
• Local storage with Room

> Browse




A Compose implementation of the Rally Material study, a financial app that focuses on data, charts, reusability and animations.

• Low complexity
• Material theming with a dark-only theme
• Custom layouts and reusable elements
• Charts and tables
• Animations
• Screenshot tests

> Browse




A Compose implementation of the Crane Material study, a travel app that uses Material Design components and Material Theming to create a personalized, on-brand experience.

• Medium complexity
• Draggable UI elements
• Android Views inside Compose
• UI state handling
• UI Tests

> Browse




A Compose implementation of the Owl Material study. The Owl brand uses bold color, shape, and typography to express its brand attributes: energy, daring, and fun.

• Medium complexity
• Material theming & light/dark themes
• Custom layout
• Animation

> Browse

�� Additional samples

Project



A catalog of Material Design components and features available in Jetpack Compose. See how to implement them and how they look and behave on real devices.

• Lives in AOSP—always up to date
• Uses the same samples as API reference docs
• Theme picker to change Material Theming values at runtime
• Links to guidelines, docs, source code, and issue tracker

> Get it on Google Play
> Browse on AOSP




A gardening app illustrating Android development best practices with Android Jetpack. The compose branch is partially built with Jetpack Compose.

• Compose working in an existing app: including integration with strings, resources, and themes and styles
• Integration with an existing architecture based on Jetpack libraries
CollapsingToolbarLayout behavior implemented manually with Compose
• Showing Snackbars with Compose

> Browse




A work-in-progress TV show tracking Android app, which connects to Trakt.tv.

• Entirely written in Kotlin and uses Kotlin Coroutines throughout
• Uses many of the Architecture Components: Room, Lifecycle, Navigation
• Uses Hilt for dependency injection

> Browse

License

Copyright 2020 The Android Open Source Project

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

    https://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
 相关资料
  • 从右到左来组合多个函数。 这是函数式编程中的方法,为了方便,被放到了 Redux 里。 当需要把多个 store 增强器 依次执行的时候,需要用到它。 参数 (arguments): 需要合成的多个函数。预计每个函数都接收一个参数。它的返回值将作为一个参数提供给它左边的函数,以此类推。例外是最右边的参数可以接受多个参数,因为它将为由此产生的函数提供签名。(译者注:compose(funcA, fu

  • Docker Compose v2 Docker Compose is a tool for running multi-container applications on Dockerdefined using the Compose file format.A Compose file is used to define how the one or more containers that

  • 主要内容:实例,Compose 安装,使用,composetest/app.py 文件代码,docker-compose.yml 配置文件,yml 配置指令参考Compose 简介 Compose 是用于定义和运行多容器 Docker 应用程序的工具。通过 Compose,您可以使用 YML 文件来配置应用程序需要的所有服务。然后,使用一个命令,就可以从 YML 文件配置中创建并启动所有服务。 如果你还不了解 YML 文件配置,可以先阅读 YAML 入门教程。 Compose 使用的三个步骤:

  • 使用 Docker Compose,您可以使用一个命令启动本地测试网络。 需求 安装 tendermint 安装 docker 安装 docker-compose 构建 构建 tendermint 二进制文件和可选 tendermint/localnode docker 映像。 注意,二进制文件将被挂载到容器中,因此可以在不重新构建镜像的情况下更新它。 cd $GOPATH/src/github.

  • Docker Compose 是 Docker 官方编排(Orchestration)项目之一,负责快速的部署分布式应用。 本章将介绍 Compose 项目情况以及安装和使用。

  • 在安装 Compose之前,你需要先安装好 Docker 。然后你需要使用 curl 指令来安装 Compose 安装 Docker 首先,你需要安装大于或者等于1compose/.6版本的 Docker 。 MAC OSX 安装指南 Ubuntu 安装指南 其它系统安装指南 安装 Compose 运行下边的命令来安装 Compose: curl -L https://githubcompose/

  • 解决多容器的 APP 部署问题。 要从 Dockerfile build image 或从 Dockerhub 拉取或从 Tar export iamge。 要创建多个 container。 要管理多个 container。(启动停止删除) 介绍Docker Compose 通过一个 yml 文件定义多容器的 docker 应用,通过一条命令就可以根据 yml 文件的定义去创建或管理这些容器。 版

  • Docker Compose 是 Docker 编排服务的一部分,Machine 可以让用户在其它平台快速安装Docker,Swarm 可以让 Docker 容器在集群中高效运转,而 Compose 可以让用户在集群中部署分布式应用。简单的说,Docker Compose 属于一个“应用层”的服务,用户可以定义哪个容器组运行哪个应用,它支持动态改变应用,并在需要时扩展。 使用Compose的第一步