File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 4444 < meta property ="og:description " content ="Buy and sell physical products as redeemable NFTs on Boson Protocol " />
4545 < meta property ="og:image " content ="https://bosonprotocol.infura-ipfs.io/ipfs/QmTC3qTdY47aVA55skZ4EcAiRWD8ZSTdRqN58Hkc9yjYMd " />
4646 <!-- using Boson Protocol Widgets -->
47- < link rel ="stylesheet " href ="%REACT_APP_WIDGETS_URL%/styles.css ">
48- < script async type ="text/javascript " src ="%REACT_APP_WIDGETS_URL%/scripts/boson-widgets.js "> </ script >
47+ < script >
48+ // Remove trailing slash from WIDGETS_URL if present
49+ window . WIDGETS_URL = '%REACT_APP_WIDGETS_URL%' . replace ( / \/ $ / , '' ) ;
50+ </ script >
51+ < link rel ="stylesheet " id ="widgets-css ">
52+ < script async type ="text/javascript " id ="widgets-js "> </ script >
53+ < script >
54+ // Set the href and src attributes after processing the URL
55+ document . getElementById ( 'widgets-css' ) . href = window . WIDGETS_URL + '/styles.css' ;
56+ document . getElementById ( 'widgets-js' ) . src = window . WIDGETS_URL + '/scripts/boson-widgets.js' ;
57+ </ script >
4958 <!-- -->
5059 </ head >
5160 < body >
You can’t perform that action at this time.
0 commit comments