Yet another Design/Code switcher for Tapestry5 applications.
Go to Window -> Show View -> Other..., filter by "Tapestry" and select "Tapestry Context".
Tapestry Context View will appear (top right on this screenshot):
classpath:
or context:
binding prefixes for assetsNote: This feature is only available in Eclipse 4.
Quick Switch provides the same navigation functionality as Tapestry Context view. Use it when you work in maximized editor mode and/or your Tapestry Context view is minimized.
Default shortcut for this pop-up is CMD+;
:
Tip: If you installed Quick Switch feature, I recommend you to change key bindings vice versa:
CMD+;
for Code/Design switch and CMD+R
for the Quick Switch pop-up:
CMD+Hover over component reference to jump to one of its definitions:
Tapestry5 completion proposals now available for all WTP Editors.
Go to Window -> Show View -> Other..., filter by "Tapestry" and select "Tapestry Project Outline".
This view displays structure of your Tapestry5 project:
web.xml
) in the "Project Explorer" to see its outlineweb.xml
, or editing your pages/components filesNote: Analysis of 3rd party modules will only work if you have sources attached to your JARs in Eclipse (which is the default if you import your project via ./gradlew eclipse
or mvn eclipse:eclipse -DdownloadSources=true
).
If you don't have sources attached to one of your module classes you will see warning icon near it in the Tapestry Project Outline view.
Note: CMD+Hover
feature won't be able to find components in the modules that don't have attached sources.
It is possible in Tapestry5 to override stack definitions, for example, this is what Tapestry5 jQuery does for core stacks. Overridden stacks will have special markers in Tapestry Project Outline view.
All symbols declared in a project collected & presented in one place.
ApplicationDefauls
or FactoryDefaults
), tapestry module where this symbol declared, and even value of the symbol.Click to open standard New Java Class dialog with pre-filled source folder and package name fields.
Create complement files for current Tapestry Context.
Click to open standard New File dialog with pre-filled location and file-name fields:
Tapestry templates and JavaScript files will be created with sample content.
Notice how cursor position is set in the new file -- it's right in the place you want to start extending it! :)
Creating JavaScript or CSS assets for page/component will add/modify @Import
annotation by putting the reference to new asset.
There are few very basic templates that come with the plugin.
Using Tapestry Context's Edit Templates menu it's now possible to edit those templates.
Selecting a template from the list will open or create corresponding file under src/main/eclipse-tapestry5
.
It's assumed that this folder will be committed to your repository and shared with your team.
page.*
templates used when creating assets within a page Tapestry Context, component.*
-- for components, etc.
Templates are not limited to just *.js
, *.css
, and *.properties
-- you may add templates with your own file extensions manually, i.e. page.coffee
or page.less
.
It is possible to have more than one set of templates organized in sub-folders.
Templates in the root of src/main/eclipse-tapestry5
will be used by default. Putting templates to sub-folder will override default templates for files created under that subfolder/package.
For example, to use different templates for all pages under com.example.app.pages.admin
package, put your templates in src/main/eclipse-tapestry5/admin
folder.
Two special snippets supported in templates: $ContextName$
and $Caret$
.
$ContextName$
will be replaced with name of a Tapestry Context for which the file was created.
$Caret$
used to position a cursor in a newly created file.
All plugin's configuration is stored in src/main/eclipse-tapestry5/config.json
which is a JSON file with some additional formatting (see GSON's lenient parsing mode).
To create this file with default content click Project Settings... from Tapestry Context's menu.
The file has some inlined comments that should be self-explanatory, i.e. default config.json
for Tapestry 5.3 can be found here.
When creating new file within Tapestry Context it's possible to specify naming convention that should be used for a name of the file:
# Naming conventions for new files. Supported values are:
# UpperCamel, lowerCamel, lower_underscode, lower-hyphen
fileNamingConventions: {
*.js = UpperCamel
, *.css = UpperCamel
, *.* = UpperCamel
}
For *.tml
and *.java
files naming convention is always UpperCamel
and cannot be overridden.
Concrete convention is picked in the order from top to bottom using simple Glob pattern matching.
Other settings can be used to help plugin to parse structure of your project, read inline comments for more details: T5.3 and T5.4.
This is still work in progress and is subject to change.
Use this update site URL:
https://raw.githubusercontent.com/wiki/anjlab/eclipse-tapestry5-plugin/update-site
Or drag & drop this icon into a running Eclipse:
update-site/target-platform.target
and click Set as Active Target Platformupdate-site/site.xml
and select Plug-in Tools -> Build Siteupdate-site
folder will contain the build and be used for local installation.YourKit supports open source projects with its full-featured Java Profiler.
YourKit, LLC is the creator of YourKit Java Profiler and YourKit .NET Profiler, innovative and intelligent tools for profiling Java and .NET applications.