Methods
# async copyToClipboard(ref, text)
Copy some text to the clipboard.
Parameters:
Name | Type | Default | Description |
---|---|---|---|
ref |
object | React reference object |
|
text |
string | null | Value to be copied |
# error(message)
Print error message
to the console if dev environment is active.
Parameters:
Name | Type | Description |
---|---|---|
message |
* | error Message to be printed to the console. |
# isDevEnvironment()
Check if the application is currently running in development mode.
# isObject(value)
Check whether a given variable is an object.
Parameters:
Name | Type | Description |
---|---|---|
value |
any | variable to be checked |
# log(message)
Print log message
to the console if dev environment is active.
Parameters:
Name | Type | Description |
---|---|---|
message |
* | Log message to be printed to the console. |
# sleep(milliseconds)
Pause execution for some amount of time.
Returns a Promise which will be resolved after the given milliseconds have passed.
Parameters:
Name | Type | Description |
---|---|---|
milliseconds |
number | time to sleep |
# useForm()
React hook to access the form context within a custom component.
# warning(message)
Print warn message
to the console if dev environment is active.
Parameters:
Name | Type | Description |
---|---|---|
message |
* | warn Message to be printed to the console. |