Skip to content

How to use <base href> and src="./foo"? #85

@benneq

Description

@benneq

Using Webpack 1.13.2 , html-loader 0.4.3 on OSX.
I'm migrating an app to Webpack and now need to use the html-loader with ngtemplate-loader.

The index.html has set <base href="https://github.com/foo/" />
And all our internal links and image sources start with ./.

For example: /folder/partial.html contains <img src="./bar/baz.png">
Though the browser will read the image from /foo/bar/baz.png

I guess that html-loader doesn't know about the base href and now tries to search for the image in /folder/bar/baz.png.

Is it somehow possible to tell html-loader about the base href?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions