toxara
11/22/2018, 12:38 PMflavorDimensions("app", "env")
register("free") { dimension = "app" }
register("paid") { dimension = "app" }
register("dev") { dimension = "env" }
register("prod") { dimension = "env" }
And let's say you have some layouts specific to free
and paid
flavors, contained in src/free/res/layout
and src/paid/res/layout
, respectively.
If I attempt to import synthetic accessors from those layouts, even though everything seems to work fine in the IDE, once I try to compile, the kotlinx.android.synthetic.free.some_layout
package cannot be resolved.
However, if I attempt to import accessors from a combined flavor (e.g. freeDev
), it works fine.
import kotlinx.android.synthetic.free.some_layout.* // doesn't work
import kotlinx.android.synthetic.freeDev.some_other_layout.* // works
With a single flavor dimension, everything works fine.
Also, I do have the Android extensions experimental mode enabled.