Thanks!
Hmm, I just copied your test case into a new test case in Scalate...
I swizzled the code ever so slightly to test the results (notice we
use result.$(cssSelector) to filter the DOM with CSS3 selectors -
cool!).
https://github.com/scalate/scalate/blob/master/scalate-core/src/test/scala/org/fusesource/scalate/scuery/WilleScueryTest.scala#L26
Seems to work for me in sbt and mvn with scala 2.8.1.
The compile error message you got seems to be that the implicit
conversion on the Transform object to a NodeSeq isn't being
recognised. I wonder which Scala compiler version you were using?
One alternative is to call the method explicitly instead (see the .toNodes)...
people.flatMap{
p =>
new Transform(node) {
$(".name").contents = p.name
$(".location").contents = p.location
}.toNodes
}
Its looking like we've currently an implicit conversion from Transform
to NodeSeq on both the Transform object and on the class.
I wonder if this import fixes it?
import org.fusesource.scalate.scuery.Transform._
Though I thought the compiler was meant to import implicit conversions
on types you have in scope?
--
James
-------
FuseSource
Email: ja...@fusesource.com
Web: http://fusesource.com
Twitter: jstrachan
Blog: http://macstrac.blogspot.com/
Open Source Integration
Done! :)
https://github.com/scalate/scalate/commit/baa8eafe1651cb1fb9a2270a635b6d8544c70ff4
should go live next website redeploy...