google analytics flask code example
Example: flask google analytics
from flask import Flask, render_template
from flask_analytics import Analytics
app = Flask(__name__)
Analytics(app)
app.config['ANALYTICS']['GAUGES']['SITE_ID'] = 'XXXXXXXXXXXXX'
@app.route('/')
def index():
return render_template('index.html')