Sage9 composer in project root directory

Hey there, I’m trying to get a WP install with a Sage 9 theme running on an immutable container server. They require composer.json to be present in the root of my repository. So I’m trying to figure out how to put Sage’s composer file in that directory and still have the packages install in the theme directory.

I tried adding the following to the end of composer.json, which still installed /vendor in the same directory as the composer.json file, not the theme directory.

"extra": {
  "installer-paths": {
    "wp-content/themes/{$name}/": ["type:wordpress-plugin"]
  }
}

and

"extra": {
  "installer-paths": {
    "wp-content/themes/{$name}/": [
      "composer/installers",
      "illuminate/support",
      "roots/sage-lib",
      "soberwp/controller",
      "squizlabs/php_codesniffer",
      "roots/sage-installer"
    ]
  }
}