Vous ne pouvez pas sélectionner plus de 25 sujets Les noms de sujets doivent commencer par une lettre ou un nombre, peuvent contenir des tirets ('-') et peuvent comporter jusqu'à 35 caractères.

README.md 930 B

12345678910111213141516171819202122232425262728293031323334
  1. sanitized_anchor_name
  2. =====================
  3. [![Build Status](https://travis-ci.org/shurcooL/sanitized_anchor_name.svg?branch=master)](https://travis-ci.org/shurcooL/sanitized_anchor_name) [![GoDoc](https://godoc.org/github.com/shurcooL/sanitized_anchor_name?status.svg)](https://godoc.org/github.com/shurcooL/sanitized_anchor_name)
  4. Package sanitized_anchor_name provides a func to create sanitized anchor names.
  5. Its logic can be reused by multiple packages to create interoperable anchor names and links to those anchors.
  6. At this time, it does not try to ensure that generated anchor names are unique, that responsibility falls on the caller.
  7. Installation
  8. ------------
  9. ```bash
  10. go get -u github.com/shurcooL/sanitized_anchor_name
  11. ```
  12. Example
  13. -------
  14. ```Go
  15. anchorName := sanitized_anchor_name.Create("This is a header")
  16. fmt.Println(anchorName)
  17. // Output:
  18. // this-is-a-header
  19. ```
  20. License
  21. -------
  22. - [MIT License](LICENSE)