How to structure a .sbt build to cross-compile with Scala and Scala.js?

The best way to do this is to have two sbt projects, with two different basedirectories that share a common source directory. This is easily done with thesourceDirectory or the unmanagedSourceDirectories setting of sbt.

Please follow our cross-building guide for details.

Can I use macros with Scala.js? What about compiler plugins?

Yes, you can. There is nothing specific to Scala.js here.

Where can I find an example of non trivial Scala.js project?

Have a look at these projects built with Scala.js.

Have you considered targeting asm.js? Would it help?

asm.js would not help in implementing Scala.js.

asm.js was designed as a target for C-like languages, that consider the memoryas a huge array of bytes, and with manual memory management. By their ownacknowledgment (see their FAQ), it is not a goodtarget for managed languages like Scala.