search

package
v0.0.0-...-cf27a83 Latest Latest
Warning

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

Go to latest
Published: May 27, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const PageSize = 2

Variables

This section is empty.

Functions

This section is empty.

Types

type Paging

type Paging struct {
	Before *int `json:"before,omitempty"`
	After  *int `json:"after,omitempty"`
}

type Request

type Request struct {
	Query string `binding:"q"`
	Page  int    `binding:"page"`
}

func (*Request) Validate

func (req *Request) Validate() error

type Response

type Response struct {
	Paging *Paging      `json:"paging"`
	Items  []*post.Post `json:"items"`
}

func Process

func Process(req *Request) (*Response, error)

Jump to

Keyboard shortcuts

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