japgolly on master
Update docs for changes in 1.4.0 (compare)
japgolly on v1.4.0
japgolly on master
Towards v1.4.1 (compare)
japgolly on master
Prepare for v1.4.0 Upgrade React to 16.6.3 React.lazy and 85 more (compare)
japgolly on v1.4.x
Add note about Reusability/Reus… doc formatting Prepare to release v1.4.0 (compare)
japgolly on v1.4.x
Test AsyncCallback.init Update Travis CI caching (compare)
japgolly on v1.4.x
Update Travis CI cache dirs Revise changelog (compare)
root
<div id="root"></div>
in your body above your script
a(b)
you now have to compose TagMods by TagMod(a, b)
. If you're upgrading from 1.1.1 I strongly recommend you go through all the changelogs from 1.1.1 to 1.7.0. I know it's a good 15 minutes of nothing but reading but there are plenty of other changes you'll run into as well if you're upgrading from 1.1.1. Firstly it's all documented in the changelogs; secondly, you should run the migration scripts that are in a lot of the changelogs as it will automate the majority of the upgrade for you. Good luck!
Hi all,
I need some help setting up my first unit test for sjs react. I have the following test:
import utest._
.....
object TestTest extends TestSuite {
val tests: Tests = Tests {
"plainElement" - {
val re: VdomElement = <.div("Good")
val c = ReactTestUtils.renderIntoDocument(re)
test(c, """<div>Good</div>""")
}
}
}
When I run it I get this error:
- TestTest.plainElement.0 2ms
scala.scalajs.js.JavaScriptException: ReferenceError: document is not defined
<jscode>.Object.renderIntoDocument(react-dom-test-utils.development.js:1163)
japgolly.scalajs.react.test.ReactTestUtils$.renderIntoDocument(ReactTestUtils.scala:66)
<jscode>.array$9(Chicken.scala:51)
scala.scalajs.runtime.AnonFunction0.apply(AnonFunctions.scala:22)
So renderIntoDocument
is erroring as there are no documents to render to.
Does anyone know what is causing this?