Skip to content
This repository has been archived by the owner on Aug 23, 2021. It is now read-only.

Provides a set of templates for scaffolding architectural repetitive tasks.

Notifications You must be signed in to change notification settings

cookpad/android-studio-templates

Repository files navigation

Cookpad Android Studio Templates - IntellJ plugin

Provides a set of templates for scaffolding architectural repetitive tasks.

Installation

Install the Cookpad Android Studio Templates IntellJ plugin in Android Studio. Instructions for how to install any plugin.

Usage

Screen template

This template adds all the required components to create a new feature based on the config provided by the user.

  • Click with right button on the module that you want to create the new feature.
  • Select New -> Other -> Cookpad Feature Screen.

  • Write the name of the new feature.
  • In the drop-down list "Add pagination support", you can choose between "none" and "Standard pagination".
  • In the drop-down list "Add delegation support", you can choose between "none", "a viewModel delegate" and "a viewModel delegate and a view delegate".

Module template

This template add a new Android Gradle module with all the basic setup that we usually require when creating a a new module.

  • Click with right button on any existing Gradle module (Android Studio does not allow to use template outside a preexisting Android module).
  • Select New -> Application -> Cookpad Module.

  • Write the name of the new module.

Cookpad codebase coupling

  • Screen template relies in two custom components declared inside the non-published Cookpad code base: SingleLiveData, used for emitting events with LiveData only one time -no caching, and FragmentViewBindingDelegate to bind the view and clear the view binding once the fragment view is destroyed. You will need to replace that parts by an analogous implementation.
  • The injection of dependencies is done via Koin.

About

Provides a set of templates for scaffolding architectural repetitive tasks.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages