Sorry - very basic... I am trying the Clojurescript quickstart guide, and have followed the instruction in detail. When trying to view the index.html in Chrome, I get this error in the console:
"[Violation] Parser was blocked due to document.write(<script>)."
This happens when running this code in base.js:
/**
* Writes a new script pointing to {@code src} directly into the DOM.
*
* NOTE: This method is not CSP-compliant. @see goog.appendScriptSrcNode_ for
* the fallback mechanism.
*
* @param {string} src The script URL.
* @private
*/
goog.writeScriptSrcNode_ = function(src) {
goog.global.document.write(
'<script type="text/javascript" src="' + src + '"></' +
'script>');
I see the comments say this is not a CSP-compliant method - - and it is probably the cause of the error. I don't understand how to use the "fallback mechanism" mentioned? If that is the solution?
Please, any pointers would be greatly appreciated.