diff --git a/src/Chromabits/Nucleus/View/Node.php b/src/Chromabits/Nucleus/View/Node.php
index <HASH>..<HASH> 100644
--- a/src/Chromabits/Nucleus/View/Node.php
+++ b/src/Chromabits/Nucleus/View/Node.php
@@ -160,18 +160,18 @@ class Node extends BaseObject implements Renderable
             throw new InvalidAttributesException($result);
         }
 
+        $attributes = $this->renderAttributes();
+        if (strlen($attributes)) {
+            $attributes = ' ' . $attributes;
+        }
+
         if ($this->selfClosing) {
             return vsprintf(
                 '<%s%s/>',
-                [$this->tagName, $this->renderAttributes()]
+                [$this->tagName, $attributes]
             );
         }
 
-        $attributes = $this->renderAttributes();
-        if (strlen($attributes)) {
-            $attributes = ' ' . $attributes;
-        }
-
         return vsprintf(
             '<%s%s>%s</%s>',
             [
Fix rendering for self-closing nodes with attributes