library

package
v0.0.40 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2024 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ServiceLibrary

type ServiceLibrary interface {
	GetFeedContent(ctx context.Context, flavour feedlib.Flavour) ([]*domain.GhostCMSPost, error)
	GetFaqsContent(ctx context.Context, flavour feedlib.Flavour) ([]*domain.GhostCMSPost, error)
	GetLibraryContent(ctx context.Context) ([]*domain.GhostCMSPost, error)
}

ServiceLibrary ...

type ServiceLibraryImpl

type ServiceLibraryImpl struct {
	APIEndpoint  string
	APIKey       string
	PostsAPIRoot string
	// contains filtered or unexported fields
}

ServiceLibraryImpl organizes library functionality APIEndpoint should be of the form https://<name>.ghost.io

func NewLibraryService

func NewLibraryService(
	onboarding onboarding.ProfileService,
) *ServiceLibraryImpl

NewLibraryService creates a new library ServiceLibraryImpl

func (ServiceLibraryImpl) GetFaqsContent

func (s ServiceLibraryImpl) GetFaqsContent(ctx context.Context, flavour feedlib.Flavour) ([]*domain.GhostCMSPost, error)

GetFaqsContent fetches posts tagged as FAQs.

func (ServiceLibraryImpl) GetFeedContent

func (s ServiceLibraryImpl) GetFeedContent(ctx context.Context, flavour feedlib.Flavour) ([]*domain.GhostCMSPost, error)

GetFeedContent fetches posts that should be added to the feed.

func (ServiceLibraryImpl) GetLibraryContent

func (s ServiceLibraryImpl) GetLibraryContent(ctx context.Context) ([]*domain.GhostCMSPost, error)

GetLibraryContent gets library content to be show under library section of the app.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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