Style borderImageRepeat Property
Example
Specify how to repeat the image-border:
document.getElementById("myDIV").style.borderImageRepeat = "round";
Try it Yourself »
Description
The borderImageRepeat property sets or returns whether the image-border should be repeated, rounded or stretched.
Browser Support
The numbers in the table specify the first browser version that fully supports the property.
Property | |||||
---|---|---|---|---|---|
borderImageRepeat | Yes | 11.0 | Yes | 6.0 | 15.0 |
Look at the borderImage property instead!
Syntax
Return the borderImageRepeat property:
object.style.borderImageRepeat
Set the borderImageRepeat property:
object.style.borderImageRepeat = "stretch|repeat|round|initial|inherit"
Property Values
Value | Description |
---|---|
stretch | Default value. The image is stretched to fill the area |
repeat | The image is tiled (repeated) to fill the area |
round | The image is tiled (repeated) to fill the area. If it does not fill the area with a whole number of tiles, the image is rescaled so it fits |
space | The image is tiled (repeated) to fill the area. If it does not fill the area with a whole number of tiles, the extra space is distributed around the tiles |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
Technical Details
Default Value: | stretch |
---|---|
Return Value: | A String, representing the border-image-repeat property of an element |
CSS Version | CSS3 |
Related Pages
CSS reference: border-image-repeat property