redditsave

package
v4.0.4 Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var URL = "https://redditsave.com"

Functions

This section is empty.

Types

type Client

type Client[C Context] struct {
	// contains filtered or unexported fields
}

func (Client) Do

func (c Client) Do(req *http.Request) (*http.Response, error)

func (*Client[C]) Include

func (c *Client[C]) Include(ctx context.Context, app apfel.MixinApp[C]) error

func (Client) ResolveURL

func (c Client) ResolveURL(ctx context.Context, url string) (string, error)

func (*Client[C]) Standalone

func (c *Client[C]) Standalone(ctx context.Context, clock syncf.Clock, refreshEvery time.Duration) error

func (Client) String

func (c Client) String() string

type Config

type Config struct {
	RefreshEvery flu.Duration `yaml:"refreshEvery,omitempty" doc:"Cookie refresh interval" default:"20m"`
}

type Context

type Context interface {
	RedditsaveConfig() Config
}

type Interface

type Interface interface {
	ResolveURL(ctx context.Context, url string) (string, error)
}

Jump to

Keyboard shortcuts

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