CSSOM
The getParameters() method of the CSSFunctionRule interface returns an array of objects representing the custom function's parameters.
Syntax
getParameters()
Parameters
None.
Return value
An array of objects containing the following properties:
name- : A string representing the name of the function parameter.
type- : A string representing the data type of the parameter, or
*if no data type was specified.
- : A string representing the data type of the parameter, or
defaultValue- : A string representing the default value of the parameter, or
nullif no default value was specified.
- : A string representing the default value of the parameter, or
If no parameters were specified in the associated @function at-rule, an empty array is returned.
Examples
See the main CSSFunctionRule reference page for an example.
Specifications
Browser compatibility
See also
- @function
来源:MDN Web Docs / Mozilla 贡献者 · 作者与贡献记录 · CC BY-SA 2.5。离线整理了版式、链接和媒体显示。
