Play 2.0 with Eclipse 3.6, Scala template editing

后端 未结 1 491
生来不讨喜
生来不讨喜 2021-02-09 16:58

I´m new to Play and Scala world, so I´m needing some help to figure out how can I edit the scala template files using Eclipse. I already installed scala ide 2.9 but when I try t

相关标签:
1条回答
  • 2021-02-09 17:04

    I experienced this just recently, too, but lucky for you I made the full migration from IntelliJ to Eclipse.

    There is some setting up you need to do with the Scala templates, but one of the easiest ways to get it done is following these steps:

    Step 1: Add file extensions

    http://help.eclipse.org/helios/index.jsp?topic=%2Forg.eclipse.platform.doc.user%2Ftasks%2Ftasks-51.xhtml

    editor preferences

    Be sure that your file extensions are properly added to the file associations.

    Step 2:

    Look at the associated editor. In the image above you'll see that the only associated editor with *.htm is Web Browser. So you'll need to hit the "Add..." button to add the Scala editor. Don't forget to set it as default :)

    Step 3:

    right-click context menu for html scala editor

    Right-click on your Scala template and be sure that you are choosing the right editor. You can also use this to switch between editors.

    Hope this helps!

    0 讨论(0)
提交回复
热议问题