When I create a CommonJS Module, any exported method is accessible.
In detail for the module I've:
- Created a new Mobile Module Project, from Appcelerator Studio, with id (for example) it.module.test
- Inside assets folder, I've created a js file called it.module.test.js
- Into it.module.test.js I have:
Now I package this module directly from Appcelerator Studio and install this module inside a Test Application.
Into this application I do:
And the result is null.
It seems that the problem is that the native module classes have being called instead of the CommonJS ones as per the docs.