@@ -75,7 +75,7 @@ def render(component: Any) -> str:
7575 def render_self_close_tag (component : Mapping [str , Any ]) -> str :
7676 if component .get ("name" ):
7777 name = component ["name" ]
78- props = _RenderUtils . render_props (component . get ( " props" , {}))
78+ props = f"{{ { ',' . join (component [ ' props' ]) } }}"
7979 contents = component .get ("contents" , "" )
8080 return f"jsx({ name } ,{ props } ,{ contents } )"
8181 if component .get ("contents" ):
@@ -85,7 +85,7 @@ def render_self_close_tag(component: Mapping[str, Any]) -> str:
8585 @staticmethod
8686 def render_tag (component : Mapping [str , Any ]) -> str :
8787 name = component .get ("name" ) or "Fragment"
88- props = _RenderUtils . render_props (component . get ( " props" , {}))
88+ props = f"{{ { ',' . join (component [ ' props' ]) } }}"
8989 contents = component .get ("contents" , "" )
9090 rendered_children = [
9191 _RenderUtils .render (child )
@@ -106,10 +106,6 @@ def render_iterable_tag(component: Any) -> str:
106106 )
107107 return f"{ component ['iterable_state' ]} .map(({ component ['arg_name' ]} ,{ component ['arg_index' ]} )=>({ children_rendered } ))"
108108
109- @staticmethod
110- def render_props (props : list [str ]) -> str :
111- return f"{{{ ',' .join (props )} }}"
112-
113109 @staticmethod
114110 def render_match_tag (component : Any ) -> str :
115111 cases_code = ""
0 commit comments