Skip to content

Latest commit

 

History

History
13 lines (10 loc) · 840 Bytes

configuration.md

File metadata and controls

13 lines (10 loc) · 840 Bytes

Configurations for Kotlin PreviewGenerator (PrevGen)

By default, PreviewGenerator works with the NameGenerator V1 engine, which has a set of predefined keys with predefined values. These can be found here. Starting from v1.0.3, we have added a CONSTANT configuration, which generates a POJO object with predefined values. This is mostly needed for testing purposes to ensure consistent output, etc.

To switch the generation to constant, you need to add the following argument into your Gradle file:

ksp {
    arg("prevgen.mode", "PREDICTABLE_MODE")
}

An example of the Gradle configuration can be found here.