mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-22 21:55:11 +00:00
docs: clarify composable default name inference (#1318)
This commit is contained in:
parent
9d40a271ee
commit
fe6f6f5868
@ -24,9 +24,9 @@ Example: (using default export)
|
||||
```js [composables/use-foo.ts or composables/useFoo.ts]
|
||||
import { useState } from '#app'
|
||||
|
||||
// It will be available as useFoo()
|
||||
// It will be available as useFoo() (pascalCase of file name without extension)
|
||||
export default function () {
|
||||
return 'foo'
|
||||
return 'bar'
|
||||
}
|
||||
```
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user