SlugFilter
The slug filter will check if a value is a slug or not.
lib/filter/slug.js:6
Methods
sanitize (value)
Inherited from
AbstractFilter
but overwritten in
lib/filter/slug.js:30
The sanitize will create a correct slug of the given value.
Parameters
Name | Type | Description |
---|---|---|
value | * | The value to sanitize |
Returned Value
String: The sanitized slug.
validate (value)
Inherited from
AbstractFilter
but overwritten in
lib/filter/slug.js:19
The validate method will check if there are now unaccepted values in the slug.
Parameters
Name | Type | Description |
---|---|---|
value | Object |
Returned Value
Boolean: True if the value is a correct slug, false otherwise