diff --git a/build.sbt b/build.sbt index f0ee44ed..6f95f213 100644 --- a/build.sbt +++ b/build.sbt @@ -15,10 +15,10 @@ ThisBuild / versionScheme := Some("early-semver") ThisBuild / scalaVersion := scala3Version lazy val tyrianVersion = TyrianVersion.getVersion -lazy val scala3Version = "3.4.2" +lazy val scala3Version = "3.5.0" lazy val tyrianDocsVersion = "0.11.0" lazy val scalaJsDocsVersion = "1.16.0" -lazy val scalaDocsVersion = "3.4.2" +lazy val scalaDocsVersion = "3.5.0" lazy val commonSettings: Seq[sbt.Def.Setting[_]] = Seq( version := tyrianVersion, diff --git a/examples/.scalafix.conf b/examples/.scalafix.conf index 647a5fd7..afbf5714 100644 --- a/examples/.scalafix.conf +++ b/examples/.scalafix.conf @@ -23,3 +23,4 @@ DisableSyntax { # noUniversalEqualityMessage = "== and != are unsafe since they allow comparing two unrelated types" # regex = [] } +OrganizeImports.targetDialect = Scala3 \ No newline at end of file diff --git a/examples/.tyrian-version b/examples/.tyrian-version index 78bc1abd..d9df1bbc 100644 --- a/examples/.tyrian-version +++ b/examples/.tyrian-version @@ -1 +1 @@ -0.10.0 +0.11.0 diff --git a/examples/bootstrap/tyrianapp.js b/examples/bootstrap/tyrianapp.js index 907ce4cf..03321737 100644 --- a/examples/bootstrap/tyrianapp.js +++ b/examples/bootstrap/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/bootstrap-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/bootstrap-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/build.sbt b/examples/build.sbt index 4aab3e53..3ae16b61 100644 --- a/examples/build.sbt +++ b/examples/build.sbt @@ -6,7 +6,7 @@ import sbtwelcome._ Global / onChangedBuildSource := ReloadOnSourceChanges lazy val tyrianVersion = TyrianVersion.getVersion -lazy val scala3Version = "3.4.1" +lazy val scala3Version = "3.5.0" lazy val commonSettings: Seq[sbt.Def.Setting[_]] = Seq( version := tyrianVersion, diff --git a/examples/clock/tyrianapp.js b/examples/clock/tyrianapp.js index b10d89e2..2076158e 100644 --- a/examples/clock/tyrianapp.js +++ b/examples/clock/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/clock-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/clock-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/counter/tyrianapp.js b/examples/counter/tyrianapp.js index 7d88fbe6..a6bd5d7b 100644 --- a/examples/counter/tyrianapp.js +++ b/examples/counter/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/counter-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/counter-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/debouncing/tyrianapp.js b/examples/debouncing/tyrianapp.js index 673e1665..2cff3c98 100644 --- a/examples/debouncing/tyrianapp.js +++ b/examples/debouncing/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/debouncing-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/debouncing-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/electron/tyrianapp.js b/examples/electron/tyrianapp.js index 7f164657..4358252d 100644 --- a/examples/electron/tyrianapp.js +++ b/examples/electron/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/electron-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/electron-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/field/tyrianapp.js b/examples/field/tyrianapp.js index dd36dd1f..5104b7a6 100644 --- a/examples/field/tyrianapp.js +++ b/examples/field/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/field-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/field-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/fs2/src/main/scala/example/Main.scala b/examples/fs2/src/main/scala/example/Main.scala index 29a6facd..8833736e 100644 --- a/examples/fs2/src/main/scala/example/Main.scala +++ b/examples/fs2/src/main/scala/example/Main.scala @@ -3,7 +3,6 @@ package example import cats.effect.IO import tyrian.Html.* import tyrian.* -import tyrian.cmds.Logger import scala.concurrent.duration.* import scala.scalajs.js.annotation.* diff --git a/examples/fs2/tyrianapp.js b/examples/fs2/tyrianapp.js index e20d133b..2486f567 100644 --- a/examples/fs2/tyrianapp.js +++ b/examples/fs2/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/fs2-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/fs2-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/http/tyrianapp.js b/examples/http/tyrianapp.js index b9ac035b..4753a1d7 100644 --- a/examples/http/tyrianapp.js +++ b/examples/http/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/http-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/http-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/http4s-dom/tyrianapp.js b/examples/http4s-dom/tyrianapp.js index 6d9ea96c..ec6e4781 100644 --- a/examples/http4s-dom/tyrianapp.js +++ b/examples/http4s-dom/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/http4s-dom-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/http4s-dom-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/main-launcher/src/main/scala/example/ChatApp.scala b/examples/main-launcher/src/main/scala/example/ChatApp.scala index 53fcf5f7..17139dbe 100644 --- a/examples/main-launcher/src/main/scala/example/ChatApp.scala +++ b/examples/main-launcher/src/main/scala/example/ChatApp.scala @@ -4,9 +4,6 @@ import cats.effect.IO import tyrian.Html.* import tyrian.* -import scala.scalajs.js -import scala.scalajs.js.annotation.* - object ChatApp extends TyrianIOApp[ChatAppMsg, ChatAppModel]: def router: Location => ChatAppMsg = Routing.none(ChatAppMsg.NoOp) diff --git a/examples/main-launcher/src/main/scala/example/CounterApp.scala b/examples/main-launcher/src/main/scala/example/CounterApp.scala index 9f8292d1..7489fd4e 100644 --- a/examples/main-launcher/src/main/scala/example/CounterApp.scala +++ b/examples/main-launcher/src/main/scala/example/CounterApp.scala @@ -4,7 +4,6 @@ import cats.effect.IO import tyrian.Html.* import tyrian.* -import scala.scalajs.js.annotation.* import scala.util.Try object CounterApp extends TyrianIOApp[Msg, Model]: diff --git a/examples/main-launcher/src/main/scala/example/Main.scala b/examples/main-launcher/src/main/scala/example/Main.scala index eb30b599..a75a4463 100644 --- a/examples/main-launcher/src/main/scala/example/Main.scala +++ b/examples/main-launcher/src/main/scala/example/Main.scala @@ -1,7 +1,6 @@ package example import cats.effect.IO -import tyrian.Html.* import tyrian.* object Main { diff --git a/examples/mario/tyrianapp.js b/examples/mario/tyrianapp.js index 4761207f..c6f107fa 100644 --- a/examples/mario/tyrianapp.js +++ b/examples/mario/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/mario-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/mario-fastopt/main.js"; TyrianApp.launch("mario"); diff --git a/examples/mill/.mill-version b/examples/mill/.mill-version index 35ad3442..bd0119f9 100644 --- a/examples/mill/.mill-version +++ b/examples/mill/.mill-version @@ -1 +1 @@ -0.11.4 +0.11.12 diff --git a/examples/project/build.properties b/examples/project/build.properties index abbbce5d..ee4c672c 100644 --- a/examples/project/build.properties +++ b/examples/project/build.properties @@ -1 +1 @@ -sbt.version=1.9.8 +sbt.version=1.10.1 diff --git a/examples/project/plugins.sbt b/examples/project/plugins.sbt index 81d57b75..c5c8041f 100644 --- a/examples/project/plugins.sbt +++ b/examples/project/plugins.sbt @@ -1,5 +1,5 @@ -addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.16.0") -addSbtPlugin("io.github.davidgregory084" % "sbt-tpolecat" % "0.4.2") -addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.10.4") -addSbtPlugin("com.github.reibitto" % "sbt-welcome" % "0.3.1") -addSbtPlugin("ch.epfl.scala" % "sbt-scalajs-bundler" % "0.21.1") +addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.16.0") +addSbtPlugin("org.typelevel" % "sbt-tpolecat" % "0.5.2") +addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.12.1") +addSbtPlugin("com.github.reibitto" % "sbt-welcome" % "0.4.0") +addSbtPlugin("ch.epfl.scala" % "sbt-scalajs-bundler" % "0.21.1") diff --git a/examples/server-examples/build.sbt b/examples/server-examples/build.sbt index 2a13a64c..ba135188 100644 --- a/examples/server-examples/build.sbt +++ b/examples/server-examples/build.sbt @@ -8,7 +8,7 @@ val LogbackVersion = "1.2.6" val MunitCatsEffectVersion = "1.0.6" lazy val tyrianVersion = TyrianVersion.getVersion -lazy val scala3Version = "3.4.1" +lazy val scala3Version = "3.5.0" Global / onChangedBuildSource := ReloadOnSourceChanges @@ -36,7 +36,7 @@ lazy val server = "io.circe" %% "circe-generic" % CirceVersion, "org.typelevel" %% "munit-cats-effect-3" % MunitCatsEffectVersion % Test, "ch.qos.logback" % "logback-classic" % LogbackVersion, - "io.indigoengine" %% "tyrian" % tyrianVersion + "io.indigoengine" %% "tyrian-tags" % tyrianVersion ) ) diff --git a/examples/server-examples/project/build.properties b/examples/server-examples/project/build.properties index e5ca1ff5..74d800f2 100644 --- a/examples/server-examples/project/build.properties +++ b/examples/server-examples/project/build.properties @@ -1,2 +1,2 @@ -sbt.version=1.9.8 +sbt.version=1.10.1 diff --git a/examples/server-examples/project/plugins.sbt b/examples/server-examples/project/plugins.sbt index aa149a16..5a8869a3 100644 --- a/examples/server-examples/project/plugins.sbt +++ b/examples/server-examples/project/plugins.sbt @@ -1,5 +1,5 @@ -addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.16.0") -addSbtPlugin("io.github.davidgregory084" % "sbt-tpolecat" % "0.4.2") -addSbtPlugin("io.spray" % "sbt-revolver" % "0.9.1") -addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.14.10") -addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.10.4") +addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.16.0") +addSbtPlugin("org.typelevel" % "sbt-tpolecat" % "0.5.2") +addSbtPlugin("io.spray" % "sbt-revolver" % "0.9.1") +addSbtPlugin("com.eed3si9n" % "sbt-assembly" % "0.14.10") +addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.12.1") diff --git a/examples/server-examples/server/src/main/scala/com/example/example/Routes.scala b/examples/server-examples/server/src/main/scala/com/example/example/Routes.scala index b9f0d77d..fb55968b 100644 --- a/examples/server-examples/server/src/main/scala/com/example/example/Routes.scala +++ b/examples/server-examples/server/src/main/scala/com/example/example/Routes.scala @@ -8,9 +8,7 @@ import org.http4s.Header import org.http4s.headers.`Content-Type` import org.http4s.MediaType import org.http4s.StaticFile -import java.io.File import fs2.io.file.Files -import tyrian.Tyrian object Routes: @@ -25,7 +23,7 @@ object Routes: case request @ GET -> Root / "spa.js" => val spa = fs2.io.file.Path( "." - ) / "spa" / "target" / "scala-3.4.1" / "spa-opt" / "main.js" + ) / "spa" / "target" / "scala-3.5.0" / "spa-opt" / "main.js" StaticFile.fromPath(spa.absolute, Some(request)).getOrElseF(NotFound(spa.absolute.toString)) case GET -> Root / "ssr" / in => diff --git a/examples/server-examples/server/src/main/scala/com/example/example/SSR.scala b/examples/server-examples/server/src/main/scala/com/example/example/SSR.scala index d0de4619..3767417a 100644 --- a/examples/server-examples/server/src/main/scala/com/example/example/SSR.scala +++ b/examples/server-examples/server/src/main/scala/com/example/example/SSR.scala @@ -2,7 +2,6 @@ package com.example.example import cats.Applicative import cats.implicits.* -import org.http4s.EntityEncoder import tyrian.* import tyrian.Html.* diff --git a/examples/subcomponents/tyrianapp.js b/examples/subcomponents/tyrianapp.js index 5353fe71..6def5cad 100644 --- a/examples/subcomponents/tyrianapp.js +++ b/examples/subcomponents/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/subcomponents-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/subcomponents-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/tailwind/src/main/html/index.js b/examples/tailwind/src/main/html/index.js index e5b15a76..35069262 100644 --- a/examples/tailwind/src/main/html/index.js +++ b/examples/tailwind/src/main/html/index.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from '../../../target/scala-3.3.1/tailwind-fastopt/main.js'; +import { TyrianApp } from "../../../target/scala-3.5.0/tailwind-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/websocket/tyrianapp.js b/examples/websocket/tyrianapp.js index a258424a..5c305af6 100644 --- a/examples/websocket/tyrianapp.js +++ b/examples/websocket/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/websocket-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/websocket-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/examples/zio/tyrianapp.js b/examples/zio/tyrianapp.js index eb9bb562..20f73831 100644 --- a/examples/zio/tyrianapp.js +++ b/examples/zio/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './target/scala-3.3.1/zio-fastopt/main.js'; +import { TyrianApp } from "./target/scala-3.5.0/zio-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/project/plugins.sbt b/project/plugins.sbt index 59597c28..78c20b99 100644 --- a/project/plugins.sbt +++ b/project/plugins.sbt @@ -2,8 +2,8 @@ addSbtPlugin("org.xerial.sbt" %% "sbt-sonatype" % "3.10.0") addSbtPlugin("com.github.sbt" %% "sbt-pgp" % "2.2.1") addSbtPlugin("org.portable-scala" % "sbt-scalajs-crossproject" % "1.3.2") addSbtPlugin("org.scala-js" % "sbt-scalajs" % "1.16.0") -addSbtPlugin("org.typelevel" % "sbt-tpolecat" % "0.5.1") -addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.11.1") +addSbtPlugin("org.typelevel" % "sbt-tpolecat" % "0.5.2") +addSbtPlugin("ch.epfl.scala" % "sbt-scalafix" % "0.12.1") addSbtPlugin("org.scalameta" % "sbt-mdoc" % "2.5.1") addSbtPlugin("com.github.sbt" % "sbt-unidoc" % "0.5.0") addSbtPlugin("com.github.reibitto" % "sbt-welcome" % "0.4.0") diff --git a/sandbox-zio/tyrianapp.js b/sandbox-zio/tyrianapp.js index 52a1712c..cf6bb376 100644 --- a/sandbox-zio/tyrianapp.js +++ b/sandbox-zio/tyrianapp.js @@ -1,5 +1,3 @@ -import { - TyrianApp -} from './.js/target/scala-3.4.2/sandbox-zio-fastopt/main.js'; +import { TyrianApp } from "./.js/target/scala-3.5.0/sandbox-zio-fastopt/main.js"; TyrianApp.launch("myapp"); diff --git a/sandbox/tyrianapp.js b/sandbox/tyrianapp.js index 8cea5288..297a15af 100644 --- a/sandbox/tyrianapp.js +++ b/sandbox/tyrianapp.js @@ -1,7 +1,5 @@ -import { - TyrianApp -} from './.js/target/scala-3.4.2/sandbox-fastopt/main.js'; +import { TyrianApp } from "./.js/target/scala-3.5.0/sandbox-fastopt/main.js"; TyrianApp.launch(document.getElementById("myapp"), { - "message": "Hello, Tyrian!" + message: "Hello, Tyrian!", }); diff --git a/tyrian/src/main/scala/tyrian/http/Request.scala b/tyrian/src/main/scala/tyrian/http/Request.scala index f62123a0..ccbb59c2 100644 --- a/tyrian/src/main/scala/tyrian/http/Request.scala +++ b/tyrian/src/main/scala/tyrian/http/Request.scala @@ -1,6 +1,5 @@ package tyrian.http -import scala.concurrent.duration.FiniteDuration import scala.concurrent.duration._ /** Describes an HTTP request. diff --git a/website/build.sbt b/website/build.sbt index 617ec02c..880cfdf0 100644 --- a/website/build.sbt +++ b/website/build.sbt @@ -15,7 +15,7 @@ import scala.concurrent.duration.DurationInt import laika.sbt.LaikaPreviewConfig import java.time.OffsetDateTime -ThisBuild / scalaVersion := "3.4.1" +ThisBuild / scalaVersion := "3.5.0" enablePlugins(LaikaPlugin, GhpagesPlugin) diff --git a/website/project/build.properties b/website/project/build.properties index abbbce5d..ee4c672c 100644 --- a/website/project/build.properties +++ b/website/project/build.properties @@ -1 +1 @@ -sbt.version=1.9.8 +sbt.version=1.10.1