Dartdoc doesn't have flag --format anymore. It's been depreciated in version 8.0.3 : https://pub.dev/packages/dartdoc/changelog#803
see also my other answer on the same topic: https://stackoverflow.com/a/79276435/21037170