0

I have a project built using ScalaJS version 1.2.0 and testing the JS built with IE 11, but it is not working.

Is assumingES6: true a problem? As it was set to false in ScalaJS version 0.6.x. If yes, then how can we set assumingES6: false in ScalaJS version 1.2.0.

4

1 回答 1

4

By default, Scala.js 1.x emits code that is compliant with ECMAScript 2015 (aka ES 6).

If that doesn't work for you, you can configure it to emit code that is compliant with ECMAScript 5.1 Strict Mode using the following sbt setting:

scalaJSLinkerConfig ~= { _.withESFeatures(_.withUseECMAScript2015(false)) }
于 2021-03-22T09:50:52.307 回答