Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions sphinx/builders/html/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -1052,7 +1052,7 @@ def css_tag(css: _CascadingStyleSheet) -> str:
if value is not None]
uri = pathto(os.fspath(css.filename), resource=True)
# the EPUB format does not allow the use of query components
if self.name != 'epub':
if not self.name.startswith('epub'):
if checksum := _file_checksum(outdir, css.filename):
uri += f'?v={checksum}'
return f'<link {" ".join(sorted(attrs))} href="{uri}" />'
Expand Down Expand Up @@ -1082,7 +1082,7 @@ def js_tag(js: _JavaScript | str) -> str:
# https://github.com/sphinx-doc/sphinx/issues/11658
pass
# the EPUB format does not allow the use of query components
elif self.name != 'epub':
elif not self.name.startswith('epub'):
if checksum := _file_checksum(outdir, js.filename):
uri += f'?v={checksum}'
if attrs:
Expand Down