Enable inline javascript in LESS
问题 I would like to use inline js in my less files but I get the following message: Inline JavaScript is not enabled. Is it set in your options? How can I enable that? 回答1: I had same problem, I use webpack with less loader, I needed to add javascript option in less loader config: { test: /\.less$/, use: [{ loader: "style-loader" }, { loader: "css-loader" }, { loader: "less-loader", options: { javascriptEnabled: true } }] } I found in the sourcecode of less compiler: https://github.com/less/less