optional externals

track optional modules
optional externals for UMD and root
fixes #339
1.3.1-beta5