2009-05-01

Getting the 'wicket:id' attribute to validate

Wicket is great. The "wicket:id" attribute is all that needs to be added to a tag to place it under program control.

If you have a finicky validator (or any validator), it may object to the attribute, which isn't part of (X)HTML.

The solution is to add a namespace declaration, like this:

<html xmlns:wicket="http://wicket.apache.org">

Mixing Java and Scala in an Eclipse Project

If you start a project off as a Scala project, then it's OK to mix in some Java source. Everything will be compiled as appropriate, and library references will work out too.

But for some projects, such as the "Dynamic Web Project," that's not an option. You must convert it to a Scala project after it's created as a Java project.

Fiddling with the contents of .project manually didn't get me anywhere.

The correct procedure, as found on Nabble, is:

As a general rule you should convert Java projects to Scala projects
by using the "Add Scala Nature" package explorer context menu action
unless you know what you're doing.