swift-doc
swift-doc copied to clipboard
Error to load CSS in Index.html [Fix] [CSS]
Hi! I believe there is an error generating the path to the 'all.css' file. A '/' is being placed at the very beginning, and this is not allowing it to be properly loaded into index.html.
Result after build documentation:
<link rel="stylesheet" type="text/css" href="/all.css" media="all" />
Expected result:
<link rel="stylesheet" type="text/css" href="all.css" media="all" />
I also encountered a similar problem, how can I solve this problem? Thank you
This is not a bug and working as intended. The generated HTML files are intended to be hosted by a web server. Opening the files from the local file system is not supported. See also #174 for a more detailed discussion.
However, please have a look into the --base-url
option. Setting this flag might already solve your problem.