Closed SachaG closed 7 years ago
With Meteor package apollo@0.1.x
, we may be able to get rid of the edit: we still need this container (see boilerplate example)AppComposer
container thanks to the current user
We'll also be able to use the current user in our resolvers with the context
(3rd parameter)
Can I claim this issue and work on it this week-end?
@kytwb sure, that'd be great! Just indicate in this thread which container you're working on so we don't duplicate the work.
@kytwb awesome! π please join the Slack room: http://slack.telescopeapp.org
We are actively discussing there about Apollo, and especially this issue π€π
@SachaG @xavcz coming back to you and on Slack this week-end to get up to speed and start working on it π
Done π
This is a starter issue, highly inspired by the great job of the folks at Hoodie. π
πππππ» Hacktoberfest: Trick or Treat!
If you havenβt yet, sign up for Hacktoberfest to earn an exclusive T-Shirt.
We are sure you can learn a cool trick or two in the process on how to hack & customize Telescope Nova! π
π€ What you will need to know
Meteor, React, Apollo, and GraphQL.
π― The Goal
Replace the various containers used in Telescope (which all use the react-list-container package) with Apollo/GraphQL equivalents.
Note: a container is a special component that doesn't display any HTML, but instead takes on the job of loading data from the server, before passing that data on to other components (thus preserving separation of concerns between containers and presentational components).
There's two types of containers in the current codebase,
ListContainer
(for multiple documents) andDocumentContainer
(for single documents).Additionally, a container can either subscribe to (i.e. load) data from the server and then pass it on, or just fetch data already stored in memory and then pass it on. With Apollo, the second use case would probably just be a Redux operation and not involve GraphQL.
π Step by Step
Working on your first Pull Request? You can learn how from this free series How to Contribute to an Open Source Project on GitHub.
PostsSingle
posts containerPostsHome
posts containerPostsDay
posts containerPostsListHeader
categories container (note: no subscription)UsersProfile
posts containerPostsEditForm
post containerUsersAccounts
user containerUserSingle
user containerPing us here, in the Telescope Slack room or on Twitter if you have any questions π
I'll leave @xavcz complete this issue with more details :)