Support passing options for tileLayer, etc

Fixes #363.