GithubHelp home page GithubHelp logo

helloscalajs's Introduction

HelloScalaJS

A minimal introduction to working with Scala.js with sbt in IntelliJ.

(Not endorsed by or in any way affiliated with Lightbend or EPFL.)

What is Scala.js?

Scala.js1 is a Scala-to-JavaScript compiler. It allows you to write type-safe, statically-checked Scala code in your favourite IDE, and compile it to optimised JavaScript which you can run in your browser.

Scala.js is not "Scala lite". "Scala.js syntax" is identical to Scala syntax, because Scala.js is Scala. Scala.js just compiles your Scala code to JavaScript instead of Java bytecode.

Scala.js gives you the best of both Scala and JavaScript. Many popular Scala libraries and extensions are fully supported in Scala.js, including Scalactic / ScalaTest2, Cats3, Akka4, Play5, and more. In addition, Scala.js facades6 have been implemented for popular JavaScript libraries and frameworks like jQuery, Plotly, React, Angular, and Vue, among many others.

What is this tutorial?

This is the first step in a series of tutorials which explain how to use Scala.js in an IntelliJ sbt project.

In this step, we will create a Scala.js project from scratch, adding the required libraries and dependencies, and will send some output to the browser console.

Open TUTORIAL.md for the step-by-step tutorial.

Click here for the next tutorial, which covers Li Haoyi's ScalaTags library.


Sources

[1] https://www.scala-js.org/

[2] https://www.scalatest.org/release_notes/3.0.0

[3] https://typelevel.org/cats/

[4] https://github.com/akka-js/akka.js/

[5] https://www.scala-js.org/libraries/skeletons.html

[6] https://www.scala-js.org/libraries/facades.html

helloscalajs's People

Contributors

awwsmm avatar

Watchers

 avatar  avatar

Forkers

capesepias

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.