2017-07-18 58 views

回答

0

//嘗試下面的添加自定義JS步驟標記之前

Step 1 : Add below layout code. 

myvendor/mytheme/Magento_Theme/layout/default.xml 

<referenceContainer name="before.body.end"> 
    <block class="\Magento\Framework\View\Element\Template" template="You_Module::js.phtml" name="module_js"/> 
</referenceContainer> 

Step 2 : Add custom.js in js.phtml file like below. 
<scrip src="example.com/jp2/test.js" /> 
相關問題