Modern Web Development with Scala


Modern Web Development with Scala
A concise step-by-step guide to the Scala ecosystem
© 2016 Denis Kalinin
Contents
Preface 1
Before we begin 2
Setting up your environment 2
Installing Java Development Kit 2
Installing Scala 3
Using REPL 4
Using IntelliJ IDEA 5
Using Atom Editor 6
Language fundamentals 8
Defining values 8
Functional types 10
Type hierarchy 11
Collections 14
Packages and imports 18
Defining classes 18
Defining objects 21
Type parametrization 22
Collections syntax revisited 22
Functions and implicits 23
Implicits and companion objects 24
Loops and conditionals 25
String interpolation 27
Traits 27
Functional programming 29
Algebraic data types 29
Pattern matching 30
Case classes 30
Higher-order functions 31
for comprehensions 34
Currying 35
Laziness 36
Option 37
Try 40
Future 42
Build tools 45
Command line 45
Gradle 46
sbt 49
Working with Play 55
Typesafe Activator 55
The Play sample application 55
Application structure 58
Play templates 60
Using template parameters 62
Serving asynchronous results 64
Adding sunrise and sunset times 65
Using JodaTime 68
Adding weather information 69
Moving logic into services 72
Injecting dependencies with MacWire 74
Managing application lifecycle 78
Intercepting requests with filters 79
Using Akka 80
Frontend integration 84
Setting up nvm 84
Choosing the versions 84
package.json 85
GruntJS and Gulp 87
Module bundlers 88
Using EcmaScript 6 with Babel 89
Explaining React 89
Separating the frontend 90
Initiliazing the frontend project 91
webpack.config.js explained 92
Using React 93
Sending data via JSON 95
Using Sass with Webpack 97
Extracting styles 99
Authenticating users 103
Installing PostgreSQL 103
Adding ScalikeJDBC 103
Storing passwords 106
Managing database evolutions 108
Authetication roadmap 111
The login page 112
Implementing the authentication service 113
Using Play Forms API 118
Showing errors on the page 121
Restricting access 123
Deployment 128
Hosting considerations 128
Preparing the distribution 128
Closing remarks 131
Appendix A. Packages 132
Appendix B. Using IntelliJ IDEA 134
出版时间: 2016
官网链接: leanpub


下载地址:

Modern Web Development with Scala.pdf
1

打赏
未经允许不得转载:finelybook » Modern Web Development with Scala

相关推荐

  • 暂无文章

评论 抢沙发

  • 昵称 (必填)
  • 邮箱 (必填)
  • 网址

觉得文章有用就打赏一下

您的打赏,我们将继续给力更多优质内容

支付宝扫一扫打赏

微信扫一扫打赏