@staticmethod<EOL><INDENT>def init_config(app):<DEDENT>
try:<EOL><INDENT>get_distribution('<STR_LIT>')<EOL>has_cairo = True<EOL><DEDENT>except DistributionNotFound:<EOL><INDENT>has_cairo = False<EOL><DEDENT>app.config.setdefault('<STR_LIT>', has_cairo)<EOL>for attr in dir(config):<EOL><INDENT>if attr.startswith('<STR_LIT>'):<EOL><INDENT>app.config.setdefault(attr, getattr(config, attr))<EOL><DEDENT><DEDENT>
Initialize configuration.

        .. note:: If CairoSVG is installed then the configuration
            ``FORMATTER_BADGES_ENABLE`` is ``True``.

        :param app: The Flask application.