compatibility with `new` and standard class inheritance

Moves setting options into the constructor, so that options are still set when calling `new` or when class is extended.