...

Source file src/github.com/yuin/goldmark/util/util_safe.go

Documentation: github.com/yuin/goldmark/util

     1  //go:build appengine || js
     2  // +build appengine js
     3  
     4  package util
     5  
     6  // BytesToReadOnlyString returns a string converted from given bytes.
     7  func BytesToReadOnlyString(b []byte) string {
     8  	return string(b)
     9  }
    10  
    11  // StringToReadOnlyBytes returns bytes converted from given string.
    12  func StringToReadOnlyBytes(s string) []byte {
    13  	return []byte(s)
    14  }
    15  

View as plain text