https://www.prisma.io/ logo
Join Slack
Powered by
# prisma-whats-new
  • t

    theraccoun

    03/02/2017, 1:55 AM
    🙂
  • s

    sashko

    03/02/2017, 1:55 AM
    Damn
  • s

    sashko

    03/02/2017, 1:55 AM
    We really need automatic docs updates
  • s

    sashko

    03/02/2017, 1:55 AM
    Something I will look into
  • t

    theraccoun

    03/02/2017, 1:55 AM
    No worries!
  • t

    theraccoun

    03/02/2017, 1:55 AM
    so once I call subscribe
  • t

    theraccoun

    03/02/2017, 1:56 AM
    still not sure how to get a return result on it
  • s

    sashko

    03/02/2017, 1:56 AM
    It returns an observable, so you call subscribe again with an observer which is the thing that has a "next" method
  • s

    sashko

    03/02/2017, 1:56 AM
    Subscriptions return multiple results so a promise isn't appropriate
  • t

    theraccoun

    03/02/2017, 1:56 AM
    ahhhh
  • t

    theraccoun

    03/02/2017, 1:57 AM
    so next will return a result?
  • t

    theraccoun

    03/02/2017, 1:57 AM
    how can i get just the latest value that came in
  • s

    sashko

    03/02/2017, 2:04 AM
    That's something you can do at the moment
  • s

    sashko

    03/02/2017, 2:04 AM
    Could be useful though!
  • s

    sashko

    03/02/2017, 2:05 AM
    We see subscriptions as more of an event source than an updating bit of data
  • t

    theraccoun

    03/02/2017, 2:12 AM
    Okay so how do i ever extract the data from the observable
  • t

    theraccoun

    03/02/2017, 2:13 AM
    And understood on the event source, but often in real-time apps the client just cares about the last thing that came in
  • t

    theraccoun

    03/02/2017, 2:14 AM
    ie use subscription as guaranteed synch between client and server
  • t

    theraccoun

    03/02/2017, 2:14 AM
    synch of model **
  • j

    jarvis

    03/02/2017, 2:31 AM
    If you want the last thing that came in if there's nothing new when you subscribe, then what you want is a BehaviorSubject right?
  • j

    jarvis

    03/02/2017, 2:32 AM
    It will pass out the last value it has even if there's not something new... this is all on subscription to the observable. @theraccoun @sashko
  • j

    jarvis

    03/02/2017, 2:32 AM
    At least that's how I have my services setup to run in my Angular app. 😛
  • s

    sashko

    03/02/2017, 2:38 AM
    Yeah if you wrap the observable in RxJS you can get that
  • w

    wallslide

    03/02/2017, 3:28 AM
    Just got this error:
    503 (Service Unavailable: Back-end server is at capacity)
    s
    • 2
    • 3
  • j

    jimmy

    03/02/2017, 5:11 AM
    is it a better idea to split out attributes into multiple 1:1 relations so that i can have finer mutation callback control and permission or to keep it all as attributes in the same model? Will there be performance/optimization issues in either case? the tutorials seem to use a lot of 1:1 relations, which i thought wasn’t good design unless for physical db reasons. Whats the best criteria when deciding to use a 1:1 relation?
    s
    • 2
    • 1
  • a

    artyom

    03/02/2017, 3:27 PM
    @sajmil @howiej @willx @huggybearikf @nil.panes @samisammour @joeray welcome all to our slack! graphcool 🚀
  • a

    amann

    03/02/2017, 5:45 PM
    Is it possible to have role based permissions, or is there a workaround for some functionality like this?
    n
    • 2
    • 1
  • d

    daver182

    03/02/2017, 7:13 PM
    it is possible to get the data associated to the current logged user? I mean in a query, not passing a variable or a filter, it feels insecure
    n
    • 2
    • 4
  • k

    kabriel

    03/02/2017, 8:21 PM
    Question for the pros here: I need to call a REST API from my client. I would rather not have REST+GraphQL in the same client, so I'm looking for options. I don't see a way to do custom integrations in Graph.cool yet, so the only option I can think of is: A) Create an object, such as APIRequest from the client, and subscribe to it, B) Add a Mutation Callback that calls my server/lambda anytime an APIRequest is created, then performs the request and update the APIRequest object with status/results, C) The client that is subscribed to this request will then get the update pushed and know the results of the request etc. -- Has anyone solved this issue for themselves yet? Does this approach even sound reasonable? Has anyone tried something like this? Trying to do stuff like integrate BrainTree or other backend REST based services that require a round-trip. Thanks!
    n
    • 2
    • 2
  • s

    schickling

    03/02/2017, 9:08 PM
    Hey there React Native developers! ⚛️ Have you already checked out React Native Express? There’s now a GraphQL section as well: http://www.reactnativeexpress.com/graphql
    🎉 3
    🍾 2
1...115116117...637Latest