github.com/muratcelep/terraform@v1.1.0-beta2-not-internal-4/website/docs/language/functions/trimspace.html.md (about)

     1  ---
     2  layout: "language"
     3  page_title: "trimspace - Functions - Configuration Language"
     4  sidebar_current: "docs-funcs-string-trimspace"
     5  description: |-
     6    The trimspace function removes space characters from the start and end of
     7    a given string.
     8  ---
     9  
    10  # `trimspace` Function
    11  
    12  `trimspace` removes any space characters from the start and end of the given
    13  string.
    14  
    15  This function follows the Unicode definition of "space", which includes
    16  regular spaces, tabs, newline characters, and various other space-like
    17  characters.
    18  
    19  ## Examples
    20  
    21  ```
    22  > trimspace("  hello\n\n")
    23  hello
    24  ```
    25  
    26  ## Related Functions
    27  
    28  * [`chomp`](./chomp.html) removes just line ending characters from the _end_ of
    29    a string.