social

package
v0.0.9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 8, 2022 License: BSD-2-Clause Imports: 6 Imported by: 0

README

Social App

A simple example of how to use struct fields as resolvers instead of methods.

To run this server

go run ./example/social/server/server.go

and go to localhost:9011 to interact

Documentation

Index

Constants

View Source
const Schema = `` /* 583-byte string literal not displayed */

Variables

This section is empty.

Functions

This section is empty.

Types

type Resolver

type Resolver struct{}

func (*Resolver) Admin

func (r *Resolver) Admin(ctx context.Context, args struct {
	ID   string
	Role string
}) (*adminResolver, error)

func (*Resolver) Search

func (r *Resolver) Search(ctx context.Context, args struct{ Text string }) ([]*searchResult, error)

func (*Resolver) User

func (r *Resolver) User(ctx context.Context, args struct{ Id string }) (user, error)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL