I have been playing around with shapes in my website using CSS and it has been all right but a bit annoying at times when manipulating them since, for instance a triangle, it is really a rectangle with a border.
For a guide on shape creating in CSS I am using CSS-tricks article about it.
I wanted to use CSS since, it is going to load faster than if I was to use images.
Few days pass, I stumble upon SVG's, I have always seen them around the web but have never delved into them. So, I am wondering, would it be simpler to use SVG's instead of these CSS 'hacks' to achieve my shapes. Couldn't find any soild information about this certain topic, so any information regarding SVG's are appreciated. (These shapes will be 1000px+ wide, hence why I didn't want to use images...)
TL;DR: What is better - cross-browser/load-time wise - when wanting to have shapes on a webpage. I just looked into SVG's wondering if it is a viable option.
EDIT
Sorry, below is the code I am using at the moment to achieve the effect, along with an image of what I am looking to achieve (Unfortunately, the person who designed the image didn't supply code for the design, only the image).
Source image
My Code (Sorry if you don't like sass)
<div class="arrow-wrap">
<div class="arrow">
<div class="arrow-text">
<h1>Services</h1>
<p>Learn more about our services by selecting one below</p>
</div>
</div>
</div>
.arrow-wrap
overflow: hidden;
display: flex
justify-content: center
position: relative
z-index: 10
.arrow
width: 0
height: 0
border-style: solid
border-width: 150px 100vw 0 100vw
border-color: $dark transparent transparent transparent
position: relative
z-index: 1
display: flex
justify-content: center
.arrow-text
text-align: center
margin-top: -130px
white-space: nowrap
position: relative
z-index: 5
h1
font-size: 50px
margin: 0
p
margin: 0
color: rgba($white, 0.8)
So, since I had to muck around to get the text working (still not perfect with scaling), I am wonder whether going the route of SVG's would be the way, that is if SVG's are more efficient at the getting the job done/loading time.
EDIT 2
Was also just thinking - to add more room to the top - to add a solid box shadow to create the illusion that it sort of a irregular pentagon (Found on YouTube here)