How to make a ionic-native plugin wrap with my custom plugin?

Hi all,
I’am writing a custom plugin with ionic2, I’v see some plugin installed in my app, they have a ionic-native wrapper in ionic-native/dist/esm/plugins, i.e CodePush, when i install it with ‘cordova plugin add cordova-plugin-code-push@latest’, and then I’ll see code-push.js in ionic-native/dist/esm/plugins, so I can import { CodePush } from ‘ionic-native’, and use it like CodePush.xxxxx().

I just want to know, how to make my custom plugin to generate the ionic-native wrapper like code push?

As far as I know the main point of ionic-native is to wrap existing Cordova plugins providing an API based on promises or observables, rather than callbacks.

If you’re writing this plugin yourself you can write the code however you like, so I’m not sure why you’d want another project to wrap it?