diff --git a/django_vite/core/tag_generator.py b/django_vite/core/tag_generator.py
index 34f2cd9..91c2291 100644
--- a/django_vite/core/tag_generator.py
+++ b/django_vite/core/tag_generator.py
@@ -47,7 +47,7 @@ def stylesheet(href: str, attrs: Optional[Dict[str, str]] = None) -> Tag:
str -- CSS link tag.
"""
- attrs_str = attrs_to_str(attrs)
+ attrs_str = attrs_to_str(attrs if attrs else {})
return f''
@@ -63,7 +63,7 @@ def stylesheet_preload(href: str, attrs: Optional[Dict[str, str]] = None) -> Tag
str -- CSS link tag.
"""
- attrs_str = attrs_to_str(attrs)
+ attrs_str = attrs_to_str(attrs if attrs else {})
return f''