Open CommanderTvis opened 3 years ago
Hmm it doesn't work since link ends with .xml
: https://github.com/Kotlin/dokka/blob/4c6ce7a2581074c9b8f3e82fb51d2d953db0d49b/plugins/base/src/main/kotlin/renderers/html/HtmlRenderer.kt#L345
Btw please keep in mind that the content of that link can be updated in the future so if you choose to publish your docs they may get out of sync as the link will point to newer version than is documented
Btw please keep in mind that the content of that link can be updated in the future so if you choose to publish your docs they may get out of sync as the link will point to newer version than is documented
shields.io more or less guarantees backward compatibility of all services.
Some resources do not have extensions at all. For example, the link to Kotlin playground script is https://unpkg.com/kotlin-playground@1
(see #3102)
It might require introducing resource type since type is needed to render a resource on HTML pages. (inside head
tag)
Any update on this?
It's not just shields.io, but many other services offering badges / status images (e.g. sonar) not working properly. As if a resource is an image can not be safely determined by URL, does it eventually make sense to remove the node.isImage()
check?
From first look, removing node.isImage()
check should be more or less safe in HtmlRenderer
(and in markdown). All usages in Dokka of ContentEmbeddedResource
are coming from images.
Resources are a different story and don't affect the changes here, as in the end we will not embed this image in Dokka, but just use img
HTML tag with remote link.
So I would say it will be rather safe to drop this check, not sure that we need additional customization here (e.g extension point). In worst case, if someone (for some unknown reason) creates ContentEmbeddedResource
via external plugin, we will embed unresolved image instead of printing strange message :)
Does anyone want to contribute this fix?
Dropping the check should be easy, but writing tests might now, so if someone wants to contribute, I would try to help :)
@whyoleg Thx for the update. I can do that :rocket:. Will propose a PR anytime soon.
Describe the bug
when compiling the following markdown:
To Reproduce
Create a project, include a markdown file with affected image and compile it to HTML.
Dokka configuration Configuration of dokka used to reproduce the bug
Installation