Javascript – Is there any frontend send request code example when the backend API use @login_required from Flask-Login?
I want to implement frontend to send logout request to the flask backend below, from flask_login import login_required, logout_user @app.route('/auth/logout', methods=['POST']) @login_required def logout(): logout_user() return "success", 200 I only know I should include the credential information inside the POST…