From 0c54c2d2831623f8266ffbd8d5dae110cf074bf4 Mon Sep 17 00:00:00 2001 From: Giulio Zausa Date: Tue, 6 Jun 2023 13:18:54 +0200 Subject: [PATCH] docs: formatting --- .prettierignore | 1 + README.md | 8 +++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/.prettierignore b/.prettierignore index aa8a768..65619f5 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,3 +1,4 @@ dist/ storybook-static/ *.typeface.json +*.md diff --git a/README.md b/README.md index 3fd85f3..2c73593 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,7 @@ function Text2D() { text="Example text" // An unique key for this instance instanceKey="unique_key" + // Optional styling props bold={false} color={new Color('#ff0000')} @@ -59,6 +60,7 @@ function Text2D() { outlineWidth={0.13} outlineOpacity={0.4} outlineColor={new Color('#0000ff')} + // Optional layouting props alignX="left" // 'left' | 'center' | 'right' alignY="top" // 'top' | 'middle' | 'bottom' @@ -66,8 +68,10 @@ function Text2D() { width={500} lineHeight={10} yShift={0} + // Gets called before updating, useful for applying imperative updates onBeforeUpdate={updateFunction} + // You can also get a ref to apply imperative mutations ref={textRef} /> @@ -107,13 +111,15 @@ function Text3DScene() {