Moles Packer is a light-weighted builder for React Native projects. You can create bundle(s), including a common (basic) bundle and one or more business bundles, from a standard React Native proejct. If pre-built common bundle supplied, you can also create business bundle from a stripped project (without ios
, android
, node_modules
etc.).
Moles Packer is one of the key members in the Moles's tool chain. Together with growing React Native, Moles Packer is also under continuous development and improvement, see ChangeLog for more details.
# install globally
npm install -g moles-packer
# command created
moles-pack -v
moles-pack-common -v
# create an
react-native init rn26
# build the project by Moles Packer
moles-pack \
--input ./rn26 \
--entry index.ios.js \
--output ./build \
--bundle
var mp = require('moles-packer');
var options = {
'input' : './rn26',
'entry' : 'index.ios.js',
'output' : './build',
'bundle' : true,
'common-bundle' : true
};
mp.pack(options, function(err) {
// !err means build success.
});
Moles is developed and maintained by Framework R&D from ctrip.com.
Any questions, please send mail to [email protected].