New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for @model and @searchable #211
Comments
Hey @mihaiblaga89 we don't have plans to support these annotations yet but open to accepting PRs on it. Also please add links to appsync docs for the same in this ticket. |
Those annotations (and a bunch more, like |
Actually Looks like @appwiz is working on this! 💯 👍 |
Auth is and was working. Tested model but it isn't. Saw somewhere that they
are baked in CF, so in theory it should not be a problem to add them as well
…On Fri, Mar 8, 2019, 00:00 Armand ***@***.***> wrote:
Actually (Looks like)[https://github.com//issues/151
<#151>] @appwiz
<https://github.com/appwiz> is working on this!
💯 👍
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#211 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AEkOuqGkx9LNCYWbp9XT3CuF_IIp5HgRks5vUYvmgaJpZM4a03Kd>
.
|
How is it possible that
|
Nope. Been using Auth with your module for about a month now, tested it,
working fine. That's why I opened the issue, because Auth was working and
model and searchable do not.
…On Fri, Mar 8, 2019, 00:19 Armand ***@***.***> wrote:
How is it possible that @auth works but @model doesn't? @auth has to be
annotated with @model as well, otherwise it throughs an error.
If it's working for you somehow could you give me an example of how you
are using it?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#211 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AEkOuugXRHywUueSvuEblYrd8VBgQP2Fks5vUZB4gaJpZM4a03Kd>
.
|
You right! it does work now! that's awesome! it uses a query expression to return null if the user id is different in the context ( I believe that's the same lib that Amplify uses ).. Just what I needed |
@mihaiblaga89 @mim-Armand anyone knows how Does your schema get deployed as-is (with the annotations)? Or does AppSync transform them somehow? |
@bboure yes it does. I'm using it successfully in production for quite some time now. After my queries and mutations I just add I'm also planning to release a package that will allow you to import gql types from other files and compile it into a single schema.graphql, to avoid that file from getting unmaintainable. |
@mihaiblaga89 Thanks @mihaiblaga89. I know about About GraphQL from different files, look at this recently closed PR #227 and this issue #230 :) |
@bboure saw them, but it's easy to make mistakes, like forget a type or something. I've forked this package https://oss.prisma.io/content/graphql-import/overview and modified it to support the AppSync's custom scalars and annotations. I just need to publish it. Basically I have all the types separated into folders/files, import them in a |
@bboure |
Are there any plans to support those annotations? At the moment, if you add
@model
to a type it will provision a DynamoDB table for you automatically. Same goes for@searchable
but for an Elasticsearch instance. I know I can provision them manually in Resources but it would be nice to do it automatically if those annotations are present.The text was updated successfully, but these errors were encountered: