def init(app=None):
app = app or Flask(__name__)
with app.app_context():
env = Environment(app)
env.load_path = [path.join(path.dirname(__file__), 'assets')]
env.url = app.static_url_path
env.directory = app.static_folder
env.auto_build = app.debug
env.manifest = 'file'
scss = Bundle('stylesheet.scss', filters='pyscss', output='stylesheet.css')
env.register('scss_all', scss)
bundles = [scss]
return bundles
评论列表
文章目录