async prompting()

in generators/backend/index.js [14:31]


  async prompting() {
    this.parent = this.options.parent;
    this.props = this.parent.props;
    const prompts = [
      {
        type: "confirm",
        name: "withBackend",
        message: "Do you want to configure your solution with a backend?",
        default: true,
        when: (answers) => !this.options.hasOwnProperty("withBackend"),
      },
    ];

    return this.prompt(prompts).then(answers => {
      this.parent.props = { ...this.parent.props, ...answers };
      this.parent.props.withBackend = ((answers.withBackend || this.parent.props.withBackend) + '').toLowerCase() === 'true'
    });
  }