Skip to content
Subhajit Sahu edited this page Mar 24, 2021 · 3 revisions

Converts string to boolean. 📰 📘


boolean.Parse(s)
// s: a string
import (
	boolean "github.com/golangf/extra-boolean"
)

boolean.Parse("1")
boolean.Parse("truthy")
boolean.Parse("not off")
// true

boolean.Parse("not true")
boolean.Parse("inactive")
boolean.Parse("disabled")
// false


References

Clone this wiki locally