urlconfig

package
v0.2.16 Latest Latest
Warning

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

Go to latest
Published: Jun 5, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

Package urlconfig centralizes public URL and route path helpers.

Index

Constants

View Source
const (
	PathHome          = "/"
	PathPost          = "/p/post"
	PathDocs          = "/docs"
	PathLinks         = "/links"
	PathSponsors      = "/sponsors"
	PathAbout         = "/about"
	PathPublish       = "/publish"
	PathSearch        = "/search"
	PathRegister      = "/login"
	PathLogin         = "/login"
	PathRss           = "/rss.xml"
	PathMessages      = "/messages"
	PathDrafts        = "/drafts"
	PathSettings      = "/settings"
	PathNotifications = "/notifications"
	PathActivate      = "/activate"
	PathResetPassword = "/reset-password"
	PathAdmin         = "/admin"
)

Public page route constants.

Variables

This section is empty.

Functions

func About added in v0.1.1

func About() string

About returns the about page path.

func Activate added in v0.1.1

func Activate() string

Activate returns the account activation path.

func Admin added in v0.1.1

func Admin() string

Admin returns the admin console path.

func Docs added in v0.1.1

func Docs() string

Docs returns the documentation path.

func DocsContent added in v0.1.1

func DocsContent(projectSlug, versionSlug, contentSlug any) string

DocsContent returns the documentation content path.

func DocsProject added in v0.1.1

func DocsProject(slug any) string

DocsProject returns the documentation project path for slug.

func Drafts added in v0.2.8

func Drafts() string

Drafts returns the drafts page path.

func FilePath

func FilePath(filename string) string

FilePath returns the public image route for filename.

func GetDefaultAvatar

func GetDefaultAvatar() string

GetDefaultAvatar returns the default avatar URL, using the CDN URL when configured.

func Home added in v0.1.1

func Home() string

Home returns the home page path.

func Links() string

Links returns the links page path.

func Login added in v0.1.1

func Login() string

Login returns the login path.

func Messages added in v0.1.1

func Messages() string

Messages returns the messages page path.

func Notifications added in v0.1.1

func Notifications() string

Notifications returns the notifications page path.

func Post added in v0.1.1

func Post() string

Post returns the post listing path.

func PostDetail added in v0.1.1

func PostDetail(id any) string

PostDetail returns the article detail path for id.

func Publish added in v0.1.1

func Publish() string

Publish returns the article publishing path.

func Register added in v0.1.1

func Register() string

Register returns the registration path.

func ResetPassword added in v0.1.1

func ResetPassword() string

ResetPassword returns the password reset path.

func Rss added in v0.1.1

func Rss() string

Rss returns the RSS feed path.

func Search() string

Search returns the search page path.

func Settings added in v0.1.1

func Settings() string

Settings returns the settings page path.

func Sponsors added in v0.1.1

func Sponsors() string

Sponsors returns the sponsors page path.

func User added in v0.1.1

func User(id any) string

User returns the public user profile path for id.

Types

This section is empty.

Jump to

Keyboard shortcuts

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