new HelperService()
Methods
(static) self.navigateTo(url)
Navigate to a given URL
Parameters:
| Name | Type | Description |
|---|---|---|
url |
string | The URL to navigate the browser to |
(static) self.queryString()
Get the query string from the location search
Returns:
The query string
(static) self.scrollTo(anchor)
Scrolls to an anchor
Parameters:
| Name | Type | Description |
|---|---|---|
anchor |
string | The anchor element's ID |
(static) self.slugify(s)
Takes a string and creates a string in slug format for URLs
Parameters:
| Name | Type | Description |
|---|---|---|
s |
string | The string |
Returns:
A slugified string
(static) self.toDate(str)
Creates a formatted date string
Parameters:
| Name | Type | Description |
|---|---|---|
str |
string | The date in string format |
Returns:
Today's date formatting as mm/dd/YYYY
(static) self.today()
Creates a formatted date string
Returns:
Today's date formatting as YYYY/mm/dd