Skip to content

What is the best practice for file name / structure? #2741

@MariuzM

Description

@MariuzM

When using ParcelJS and running npm run prod, it does not account for images being in different directory and thus when loading the page images are not loaded.

So i have background image placed in CSS (src folder)
background-image: url(../img/cover.png);

After Parcel it moves all the files to one main folder but it does not change the cover.png destination.
background-image: url(../cover.ff2eb614.png);

For me to fix i would need to remove .
background-image: url(./cover.ff2eb614.png);

So I'm wandering is there a best practice for these things? So currently my workflow is build and copy all files to my VPS via sFTP

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions