Issue
Okay, yes the title is confusing. I have no clue how to write this into a title.
I have an app.route in flask for some assets.
@app.route('/assets/css/<path:path>')
def send_css(css_file):
return send_from_directory('assets/css', css_file)
What happens In the browser is that "assets/css" becomes one folder called "assets/css" like the image below:
How do I get the file structure to be like:
assets > css > style.css
and not:
assets/css > style.css
Solution
This:
> assets/css
> style.css
is the same thing as this:
> assets
> css
> style.css
The reason it shows up like that is to save space in the browser, because css
is empty.
If you added another placeholder folder or file into css, you'd see it show up like this:
> assets
> placeholder
> css
> style.css
Answered By - half of a glazier
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.