I am using playframework for an application. I am finding some in inconsistencies with the documentation. Such as, in the documentation it is written that the constructor of the class FakeHeaders should have a map of string and seq of string. This is written in the Documentation.
case class FakeHeaders (data: Map[String, Seq[String]]) extends Headers with Product with Serializable
This is the link of the documentation.
But when I am writing it, I am getting a compilation error saying that FakeHeaders should have a seq instead of a map.
This is the error I am getting.
[error] found : Map[String,Seq[String]]
[error] required: Seq[(String, Seq[String])]
I believe it is because the framework that I am using is old. But I don't kow what version I am using. How do I find out the playframework version of an existing project?
I hope I have made my question clear. If there is some confusion then please ask. Thanks in advance.
Type playVersion within the activator console.
You can run the created application and view the result in the default browser http://localhost:9000. To run a Play application: Create a new Run Configuration – From the main menu, select Run -> Edit Configurations. Click on the + to add a new configuration.
sbt : The sbt settings that describe building your application. /conf : Configuration files for your application. /project : Further build description information. /public : Where static, public assets for your application are stored. /test : Where your application's test code will be stored.
Installation from the binary package In general, the installation instructions are as follows. Install Java. Download the latest Play binary package and extract the archive. Add the 'play' command to your system path and make sure it is executable.
In plugins.sbt
:
addSbtPlugin("com.typesafe.play" % "sbt-plugin" % "2.3.8")
My version is 2.3.8
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With