Skip to content

Conversation

@olafurpg
Copy link
Contributor

@olafurpg olafurpg commented Jan 9, 2017

No description provided.

@olafurpg
Copy link
Contributor Author

olafurpg commented Jan 9, 2017

I can remove the reference to sbt-web-scalajs and sbt-gzip, or move it to the "tools" section in https://www.scala-js.org/libraries/libs.html.

Use gzip to compress the size of your `fullOptJS` output.
Optionally, the sbt plugin [`sbt-web-scalajs`](https://github.com/vmunier/sbt-web-scalajs)
can be used in combination with [`sbt-gzip`](https://github.com/sbt/sbt-gzip)
to automatically compress Scala.js assets as part of your build pipeline.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be phrased in a way that:

  • Does not imply it is necessary as part of the tutorial steps
  • For sbt-gzip, that it's only relevant once the developer actually chose to use sbt-web (or Play or something else using sbt-web).

Right now people will get confused trying to add sbt-web-scalajs to their tutorial build, which is totally not going to work given that the tutorial is a front-end-only project. There should be something like:

When deploying Scala.js to an actual web server, you should additionally gzip the resulting .js files, as usual. The setup depends on your server stack. A common setup is through sbt-web-scalajs and sbt-gzip if you have a Play or Akka-http server, or anything stack relying on sbt-web.

@olafurpg
Copy link
Contributor Author

olafurpg commented Jan 9, 2017

I adapted your proposed text. Is this better?

Copy link
Member

@sjrd sjrd left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, much better. Thanks.

@sjrd sjrd merged commit ef37572 into scala-js:master Jan 9, 2017
@olafurpg
Copy link
Contributor Author

olafurpg commented Jan 9, 2017

Yay 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants