title: Defining dimensions in Kotlin DSL for gradle
body: <p>I'm converting my <code>build.gradle</code> to Kotlin DSL. I have 2 build flavors in the app, and I can't figure out how to set the dimension for the flavors:</p>
  
  <pre><code>flavorDimensions("type")
  
  productFlavors {
      create("free") {
          buildConfigField("boolean", "IS_DONATE", false.toString())
          dimension = "type"
      }
      create("donate") {
          buildConfigField("boolean", "IS_DONATE", true.toString())
          dimension = "type"
      }
  }
  </code></pre>
  
  <p>the <code>dimension = "type"</code> part is failing; how do you set the dimension to each flavor?</p>