Skip to content

Path of dynamic chunks is relative #42

Open
@bluesurfer

Description

@bluesurfer

The chunks resulting from a dynamic import are incorrectly loaded into the page. Their path is relative to the page thus
causing 404 errors. To solve this I try to set the publicPath in Webpack config as suggested in webpack/webpack#7968

    output: {
        path: path.resolve(__dirname, 'dist'),
        publicPath: "/",
        filename: "[name].[contenthash].js",
    },

Unfortunately that raises a Django SuspiciousFileOperation:

The joined path (/main.9ce82b7ec94c17ac77f9.css) is located outside of the base path component

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingquestionFurther information is requested

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions