Hi, can you help me? What I need is to get an svg file through an ajax request using angular 2 I have it in jquery but I would get it using the HttpClient method
Is this possible?
current code
- get_svg_elm = function (url) {
- var elm = "";
- $.ajax({
- url: "assets/img/data_svg/" + url,
- data: "",
- async: false,
- dataType: "xml",
- success: function (svg) {
- elm = svg.documentElement.innerHTML;
- }
- });
- return elm;
- }
Jaganathan BantheswaranPosted Jul 31, 2018, 6:15 AM