Skip to content

Commit 213d2c3

Browse files
committed
fix: make textinstance no-op instead of warn
1 parent 4157481 commit 213d2c3

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

packages/fiber/src/core/renderer.ts

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -301,9 +301,8 @@ function createRenderer<TCanvas>(_roots: Map<TCanvas, Root>, _getEventPriority?:
301301
})
302302
}
303303

304-
// Don't handle text instances, warn on undefined behavior
305-
const handleTextInstance = () =>
306-
console.warn('Text is not allowed in the R3F tree! This could be stray whitespace or characters.')
304+
// Don't handle text instances, make it no-op
305+
const handleTextInstance = () => {}
307306

308307
const reconciler = Reconciler<
309308
HostConfig['type'],

0 commit comments

Comments
 (0)