Skip to content

anhthong381996/go-english-gen

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Generate real english words for your project.

Words file: /usr/share/dict/words (~250000 words)

=============

Usage

import "englishgen"

Ranged generators

These will generate a string with a variable number of elements specified by a range you provide

// generate a word with at least min letters and at most max letters.
Word(min, max int) string  

// generate a sentence with at least min words and at most max words.
Sentence(min, max int) string

// generate a paragraph with at least min sentences and at most max sentences.
Paragraph(min, max int) string

Convenience functions

Generate some commonly occuring tidbits

Host() string
Email() string
Url() string

Releases

No releases published

Packages

No packages published

Languages

  • Go 100.0%