Closed
Description
Not sure if I should've opened a new issue or not, and I know this is like 1.5 years ago, but I FINALLY just tried this.
Sadly, I couldn't get it to work.
Specifically: public_path = chunk_file.get("publicPath")
ends up looking like "auto023cc06898b0b15eeedc.svg"
. After playing with it for a while, I realized the webpack-stats.json
looks like this:
"023cc06898b0b15eeedc.svg": {
"name": "023cc06898b0b15eeedc.svg",
"path": "...",
"publicPath": "auto023cc06898b0b15eeedc.svg"
},
}
"chunks": { ... },
"publicPath": "auto"
So, I believe it is supposed to be:
public_path = self.get_assets().get("publicPath", None)
if public_path != "auto":
return public_path
Above probably isn't great to call get_assets()
every file even if it is cached. Probably recommend passing assets into the get_chunk_url
I'm not 100% sure if this is correct though, so welcome to feedback first.
Metadata
Metadata
Assignees
Labels
No labels