Do I use , <>, >

后端 未结 15 2074
借酒劲吻你
借酒劲吻你 2020-11-22 06:10

Should I use , , or for loading SVG files into a page in a way similar to loading a jpg
15条回答
  •  眼角桃花
    2020-11-22 06:58

    I would personally use an tag because if you do you have full control over it. If you do use it in you don't get to control the innards of the SVG with CSS etc.

    another thing is browser support.

    Just open your svg file and paste it straight into the template.

    
      
        
        
        
        
        
      
    

    then in your css you can simply eg:

    svg {
      fill: red;
    }
    

    Some resource: SVG tips

提交回复
热议问题