Flows gets deleted from app.json

Hi, I am justing starting a little development trials on my homey, but get some weird things (at least to me). Could not find a solutions on the forum and the documentation is poor (sorry).

I just started a new app to test out.

app.js

'use strict';

const Homey = require('homey');
const t = require('./lib/tools');

class ToolBox extends Homey.App {

	onInit() {
		this.log('Toolbox is running')
		t.log('APP', 'Toolbox is started');

		t.log('APP', 'Create Action Card ask_question');
		let askQuestion = new Homey.FlowCardAction('ask_question');

		t.log('APP', 'Action Card ask_question created');
		askQuestion
			.register()
			.registerRunListener(async ( args, state ) => {
				t.log('APP', 'Listener for Card ask_question created');
				return true;
			})
	}
}

module.exports = ToolBox;

in app.json I have

{
  "id": "eu.yormedia.ToolBox",
  "version": "1.0.0",
  "compatibility": ">=2.4.0",
  "sdk": 2,
  "name": {
    "en": "ToolBox",
    "nl": "ToolBox"
  },
  "description": {
    "en": "A versatile application ",
    "nl": "Een veelzijdige applicatie"
  },
  "images": {
    "large": "/assets/images/large.png",
    "small": "/assets/images/small.png"
  },
  "author": {
    "name": "yormedia",
    "email": "info@yormedia.eu"
  },
  "category": [
    "tools"
  ],
  "permissions": [
    "homey:manager:speech-input",
    "homey:manager:speech-output"
  ],
  "flow": {
    "actions": [
      {
        "id": "ask_question",
        "title": {
          "en": "Ask a question",
          "nl": "Stel een vraag"
        }
      }
    ]
  }
}

When I either run or validate the flow section will be deleted out of my app.json.

Any help will be appreciated.

Thank you

Carlo

(t.log is just a console log for my own flow debug)

A user on Slack had the exact same issue: https://athomcommunity.slack.com/archives/C04SUGZ9E/p1588260455076800

By default, an app created using homey app create will use the Compose plugin, which is causing this behaviour. See the fine manual on how it works. Alternatively, remove the compose plugin from .homeyplugins.json.

Robert,

Thanks…

By default, an app created using homey app create will use the Compose plugin, which is causing this behaviour. See the fine manual on how it works. Alternatively, remove the compose plugin from .homeyplugins.json .

Touche, after reading this comment I could solve it in 30 seconds.
The documentation is less poor then I gave credit, just was looking in the wrong direction…

I have choosen to embrase the compose feature. As it segments my various components and makes it easier to troubleshoot.

Thanks a lot…

And I want to appologize to Athom about my remarks on poor documentation it was I myself that did not read propperly.

Cheers,

Carlo