Home / Function/ WriteString() — gin Function Reference

WriteString() — gin Function Reference

Architecture documentation for the WriteString() function in text.go from the gin codebase.

Entity Profile

Dependency Diagram

graph TD
  cf61522e_16ad_1abc_122e_85489bb44c39["WriteString()"]
  4c747794_88bd_f8d4_35d3_543d97a84516["Render()"]
  4c747794_88bd_f8d4_35d3_543d97a84516 -->|calls| cf61522e_16ad_1abc_122e_85489bb44c39
  style cf61522e_16ad_1abc_122e_85489bb44c39 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

render/text.go lines 33–41

func WriteString(w http.ResponseWriter, format string, data []any) (err error) {
	writeContentType(w, plainContentType)
	if len(data) > 0 {
		_, err = fmt.Fprintf(w, format, data...)
		return
	}
	_, err = w.Write(bytesconv.StringToBytes(format))
	return
}

Subdomains

Called By

Frequently Asked Questions

What does WriteString() do?
WriteString() is a function in the gin codebase.
What calls WriteString()?
WriteString() is called by 1 function(s): Render.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free