소스 검색

add contentUrl to utils

weichen 4 년 전
부모
커밋
23869db9f9
1개의 변경된 파일4개의 추가작업 그리고 0개의 파일을 삭제
  1. 4 0
      backstage/static/js/utils.js

+ 4 - 0
backstage/static/js/utils.js

@@ -23,4 +23,8 @@ function removeDescElement(p, textArea, inputButton, removeButton) {
 
 function removeDescData(blockArray, blockIndex, dataIndex) {
   blockArray[blockIndex].data.splice(dataIndex, 1);
+}
+
+const contentUrl = () => {
+  return 'http://localhost:1313' + (JSON.parse(document.getElementById('url').textContent)).url + '/';
 }