In Flarum, post content is formatted with a minimal TextFormatter configuration by default. The bundled Markdown and BBCode extensions simply enable the respective plugins on this TextFormatter configuration.

You can configure the TextFormatter Configurator instance in your extension using the Formatter extender: