Created
December 24, 2017 11:39
-
-
Save trepidacious/107352f925d736bea5989a156138beaa to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| def stringViewThing = ReactComponentB[String]("StringViewThing") | |
| .render_P(s => <.div(s): ReactElement) | |
| .configure(Reusability.shouldComponentUpdateWithOverlay) | |
| .componentWillUnmount(_ => Callback{println("StringViewThing unmounted! Again!")}) | |
| .build | |
| val streetView = cursorView[Unit, Street, StreetDelta, Unit]("StreetView") { c => { | |
| val r = <.div( | |
| ^.paddingTop := "20px", | |
| ^.backgroundColor := MaterialColor.Amber.a100, | |
| stringViewThing.withKey("stringOfNumber")(c.model.number.toString)//, | |
| ) | |
| console.log(r) | |
| r | |
| }} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment