Ver Fonte

docs(cookbook): Fix typo: change 'node' to 'nodes' (#805)

* docs(cookbook): Fix typo: change 'node' to 'nodes'

* docs(cookbook): Fix Bind text prop as a string in <Text3D> component

---------

Co-authored-by: Alvaro Saburido <alvaro.saburido@gmail.com>
RAMTAKH Mehdi há 7 meses atrás
pai
commit
b9827d8e28
2 ficheiros alterados com 4 adições e 4 exclusões
  1. 1 1
      docs/cookbook/load-models.md
  2. 3 3
      docs/cookbook/text-3d.md

+ 1 - 1
docs/cookbook/load-models.md

@@ -95,7 +95,7 @@ const { nodes } = await useGLTF('/models/AkuAku.gltf', { draco: true })
 </script>
 
 <template>
-  <primitive :object="node.AkuAku" />
+  <primitive :object="nodes.AkuAku" />
 </template>
 ```
 :::

+ 3 - 3
docs/cookbook/text-3d.md

@@ -209,8 +209,8 @@ import { Text3D } from '@tresjs/cientos'
 
 We can pass the options as props
 
-```html
-<Text3D :font="fontPath" :text="my 3d text" :size="0.8" />
+```vue
+<Text3D :font="fontPath" :text="'my 3d text'" :size="0.8" />
 ```
 
 in case the options are not provided, the default values will be:
@@ -229,5 +229,5 @@ bevelSegments: 4,
 By default text in ThreeJS starts at the mesh initial position, so it's [0,0,0] and the text will start there but we can center it by just passing the flag "center"
 
 ```vue
-<Text3D :font="fontPath" :text="my 3d text" center />
+<Text3D :font="fontPath" :text="'my 3d text'" center />
 ```