新的激活器会创建正确的Scala Play解剖结构吗? [英] Does `activator new` create the correct Scala Play anatomy?

查看:82
本文介绍了新的激活器会创建正确的Scala Play解剖结构吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

根据 Scala Play应用程序布局文档,其结构如下所示:

According to the Scala Play application layout documentation the anatomy looks as follows:

 app                      → Application sources
  └ assets                → Compiled asset sources
     └ stylesheets        → Typically LESS CSS sources
     └ javascripts        → Typically CoffeeScript sources
  └ controllers           → Application controllers
  └ models                → Application business layer
  └ views

发布activator new时:

似乎省略了models目录:

某些Play示例包含一个models目录,而执行activator new则不是这种情况.

Some Play examples contain a models directory, while this is not the case when activator new is executed.

推荐答案

是.文件夹app等效于传统Scala或Java项目中的src/main/scalasrc/main/java,因此其下的文件夹是开发人员定义的.

Yes. The folder app is equivalent to src/main/scala or src/main/java in a traditional Scala or Java project, so what resides under it is developer-defined.

顺便说一句, SBT现在支持Giter8 ,因此您可以尝试使用播放Scala种子来生成项目如果您想对我的回答进行核对.

On an aside, SBT now supports Giter8, so you could try generating a project using the Play Scala Seed if you would like to sense-check my answer.

这篇关于新的激活器会创建正确的Scala Play解剖结构吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆