app = Quart(__name__, template_folder='templates', static_folder='static')
app.jinja_env.globals['emojiflags'] = emojiflags
or
app = Flask(__name__, template_folder='templates', static_folder='static')
app.add_template_global(name='emojiflags', f=emojiflags)