Skip to content
Snippets Groups Projects
Commit 6d440e7e authored by Reiter, Christoph's avatar Reiter, Christoph :snake:
Browse files

Don't use an absolute path for locating the json data

parent af8a141e
No related branches found
No related tags found
No related merge requests found
...@@ -31,7 +31,7 @@ class Icon extends LitElement { ...@@ -31,7 +31,7 @@ class Icon extends LitElement {
} }
render() { render() {
let svg = fetch('/local/vpu-common/icons/' + this.name + '.json').then(response => { let svg = fetch('local/vpu-common/icons/' + this.name + '.json').then(response => {
return response.json().then(data => { return response.json().then(data => {
return unsafeHTML('<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" style="pointer-events: none; display: block; width: 100%; height: 100%;">' +'<path d="' + data + '" />' + '</svg>'); return unsafeHTML('<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" style="pointer-events: none; display: block; width: 100%; height: 100%;">' +'<path d="' + data + '" />' + '</svg>');
}); });
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment