Simply-Static / simply-static

Convert your WordPress site into a static one with the free WordPress static site generator plugin, Simply Static.
https://simplystatic.com
GNU General Public License v2.0
196 stars 48 forks source link

Handle Base64 encoded scripts #150

Open AndrewKahr opened 1 year ago

AndrewKahr commented 1 year ago

When using certain minifiers/js optimizers like autoptomize, scripts are encoded into base64. This leads to any links within the script not being replaced.

Would it be possible for simply static to decode base64 within script tags encoded as base64, replace urls, then reencode as base64?

Example: <script src="data:text/javascript;base64,DQERWSRERWERE...."></script>

patrickposner commented 1 year ago

Related: https://github.com/Simply-Static/simply-static/issues/151