Package readmode tools for working with readmode-css ( https://codeberg.org/reiver/readmode-css ), for the Go programming language.
  • CSS 59.6%
  • Go 40.4%
Find a file
2025-10-06 16:14:26 -07:00
.gitmodules remove git submodule 2025-09-02 05:04:46 -07:00
defaultpaths.go default path 2025-09-06 16:56:37 -07:00
embed.go readmode.css 2025-09-02 05:06:13 -07:00
etag.go etag 2025-09-03 06:10:49 -07:00
go.mod httprec update 2025-09-20 06:14:43 -07:00
go.sum httprec update 2025-09-20 06:14:43 -07:00
httphandler.go added support for XHTML, too 2025-10-06 16:14:26 -07:00
inject.go correction 2025-09-06 18:33:37 -07:00
LICENSE initial commits 2025-09-02 04:46:27 -07:00
README.md readmode.HTTPHandler() 2025-09-03 05:47:33 -07:00
readmode.css updated readmode.css 2025-09-03 05:24:02 -07:00

go-readmode

Package readmode tools for working with readmode-css, for the Go programming language.

Documention

Online documentation, which includes examples, can be found at: http://godoc.org/github.com/reiver/go-readmode

GoDoc

How To Use

The content of the readmode.css is contained in the variable readmode.CSS

You would likely somehow return this from an http.Handler when the correct path is requested.

For example:

import "github.com/reiver/go-readmode"

func serveHTTP(responseWriter http.ResponseWriter, request *http.Request) {
	responseWriter.Header().Add("Content-Type", "text/css")
	io.WriteString(responseWriter, readmode.CSS)
}

Or, you could just use readmode.HTTPHandler:

handler = readmode.HTTPHandler(httphandler, "/css/readmode.css")

Import

To import package readmode use import code like the following:

import "github.com/reiver/go-readmode"

Installation

To install package readmode do the following:

GOPROXY=direct go get github.com/reiver/go-readmode

Author

Package readmode was written by Charles Iliya Krempeaux