flask-assets

Cant generate all.css file from sass files with flask-assets

邮差的信 提交于 2020-01-16 00:37:42
问题 I became tired of using css in my flask app so I decided to move to scss with flask assets https://github.com/miracle2k/flask-assets. I added this in my app.py file: from flask_assets import Environment, Bundle assets = Environment(app) assets.debug = True assets.url = app.static_url_path scss = Bundle('sass/foo.scss', 'sass/bar.scss', filters='pyscss', output='gen/all.css') assets.register('scss_all', scss) If I understand correctly, these lines are supposed to go check my static/sass folder

Flask-Assets working locally but not on Heroku

▼魔方 西西 提交于 2019-12-20 04:46:21
问题 I'm working to modify a cookiecutter Flask app. I'm working locally on WIN7 and attempting to deploy to heroku. I'm currently trying to add a datepicker to a page. I've found https://eonasdan.github.io/bootstrap-datetimepicker/. The structure of myflaskapp: I've set up bower to install the front end dependencies under the static root by using a .bowerrc file in the document root containing: { "directory" : "myflaskapp/static/bower_components" } This cookiecutter uses flask-assets to manage

Flask-Assets working locally but not on Heroku

放肆的年华 提交于 2019-12-20 04:46:17
问题 I'm working to modify a cookiecutter Flask app. I'm working locally on WIN7 and attempting to deploy to heroku. I'm currently trying to add a datepicker to a page. I've found https://eonasdan.github.io/bootstrap-datetimepicker/. The structure of myflaskapp: I've set up bower to install the front end dependencies under the static root by using a .bowerrc file in the document root containing: { "directory" : "myflaskapp/static/bower_components" } This cookiecutter uses flask-assets to manage

GAE: Flask/webassets throws an expection on {% extends “base.html” %}

僤鯓⒐⒋嵵緔 提交于 2019-12-19 10:27:11
问题 I am trying to port my existing flask app into google app engine. After a lot of reading and solving issues, I came across a problem I am completely stuck with: Upon starting the app on my local environment, I get this error message: Short version: {% extends "base.html" %} OSError: [Errno 38] Function not implemented How can this function not be implemented? It is part of flask/jinja2. Longer version: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> <title>500 Internal Server Error<

How to pass filter specific configuration options in webassets

↘锁芯ラ 提交于 2019-12-11 05:38:33
问题 Using flask, flask-assets, webassets I am trying to pass a filter specific configuration for a particular filter in webassets, but haven't been able to do so, so far. Have read the documentation multiple times to no avail. Have also gone through the source code, but that hasn't helped either. Specifics: The filter I'm trying to use is cleancss And the particular configuration I'm trying to pass is --skip-rebase According to the link to cleancss docs above, I should be able to pass the --skip

Autoprefixer Filter Not Working in Flask_Assets

不想你离开。 提交于 2019-12-11 00:58:47
问题 I have tried to get the autoprefixer filter to work with flask_assets by following the instructions in the Flask_Assets documentation, but it does not appear to apply the filter. Here is my code: # construct flask app object from flask import Flask, render_template_string flask_args = { 'import_name': __name__ } flask_app = Flask(**flask_args) from flask_assets import Environment, Bundle assets = Environment(flask_app) assets.config['AUTOPREFIXER_BIN'] = 'postcss' assets.config['AUTOPREFIXER

Flask-Assets working locally but not on Heroku

杀马特。学长 韩版系。学妹 提交于 2019-12-02 05:31:48
I'm working to modify a cookiecutter Flask app. I'm working locally on WIN7 and attempting to deploy to heroku. I'm currently trying to add a datepicker to a page. I've found https://eonasdan.github.io/bootstrap-datetimepicker/ . The structure of myflaskapp: I've set up bower to install the front end dependencies under the static root by using a .bowerrc file in the document root containing: { "directory" : "myflaskapp/static/bower_components" } This cookiecutter uses flask-assets to manage the project assets. Following https://adambard.com/blog/fresh-flask-setup/ I've modified myflaskapp

GAE: Flask/webassets throws an expection on {% extends “base.html” %}

扶醉桌前 提交于 2019-12-01 11:18:01
I am trying to port my existing flask app into google app engine. After a lot of reading and solving issues, I came across a problem I am completely stuck with: Upon starting the app on my local environment, I get this error message: Short version: {% extends "base.html" %} OSError: [Errno 38] Function not implemented How can this function not be implemented? It is part of flask/jinja2. Longer version: <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> <title>500 Internal Server Error</title> <h1>Internal Server Error</h1> <p>The server encountered an internal error and was unable to