X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/427f5457d9699c319a1957940a50dea887b00f9d..9efa2c7b92952b7d72bd5dc35dd22deb79d50b35:/app/assets/javascripts/id.js diff --git a/app/assets/javascripts/id.js b/app/assets/javascripts/id.js index 687f1e044..dd7cd3325 100644 --- a/app/assets/javascripts/id.js +++ b/app/assets/javascripts/id.js @@ -1,5 +1,7 @@ //= require iD +/* globals iD */ + document.addEventListener("DOMContentLoaded", function() { var container = document.getElementById("id-container"); @@ -12,7 +14,7 @@ document.addEventListener("DOMContentLoaded", function() { var id = iD.Context() .embed(true) .assetPath("iD/") - .assetMap(container.dataset.assetMap) + .assetMap(JSON.parse(container.dataset.assetMap)) .locale(container.dataset.locale, container.dataset.localePath) .preauth({ urlroot: location.protocol + "//" + location.host,