Auto Imports in Pinia Store #203
Unanswered
John-Church
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello,
I hope this is the appropriate place to ask this! I was wondering if anyone has any advice on getting auto-imports to work with Pinia stores?
For example, if you had a query
launches
that generates a functionGqlLaunches
then you automatically have access to that function in<script setup>
. I'm not too sure how that works. How would one go about extending that auto-importation functionality to/store/launch.ts
or a similar Pinia store file?I know you can just add
import { GqlLaunches } from '#build/gql'
but is there a way to auto-import instead?
Thank you for any help! I've tried searching for some info on this but it seems to be in that mysterious middle ground of "not an absolute beginner javascript question" but "still pretty general" where it is hard to find good information.
Beta Was this translation helpful? Give feedback.
All reactions