Skip to content

Commit 7d7e3c2

Browse files
committed
improve warning
1 parent 8c6b238 commit 7d7e3c2

File tree

1 file changed

+12
-6
lines changed

1 file changed

+12
-6
lines changed

src/idom/core/vdom.py

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -160,12 +160,18 @@ def vdom(
160160
if isinstance(child, dict) and "tagName" not in child:
161161
warn(
162162
(
163-
"Element constructor signatures have changed! This will be an "
164-
"error in a future release. A CLI tool for automatically updating "
165-
"code to the latest API has been provided with this release of "
166-
"IDOM (e.g. 'idom update-html-usages'). However, it may not "
167-
"resolve all issues arrising from this change. Start a discussion "
168-
"if you need help transitioning to this new interface: "
163+
"Element constructor signatures have changed! This will be an error "
164+
"in a future release. All element constructors now have the "
165+
"following usage where attributes may be snake_case keyword "
166+
"arguments: "
167+
"\n\n"
168+
">>> html.div(*children, key=key, **attributes) "
169+
"\n\n"
170+
"A CLI tool for automatically updating code to the latest API has "
171+
"been provided with this release of IDOM (e.g. 'idom "
172+
"update-html-usages'). However, it may not resolve all issues "
173+
"arrising from this change. Start a discussion if you need help "
174+
"transitioning to this new interface: "
169175
"https://github.com/idom-team/idom/discussions/new?category=question"
170176
),
171177
DeprecationWarning,

0 commit comments

Comments
 (0)