Meteor Packages for < 1.3 and > 1.3 at the same time


#1

Hello Everybody!
I would like to know if there is any way to develop a meteor package that is compatible both with below 1.3 and 1.3 at the same time. Do we need to do anything special?
I would like to write it with imports and all the stuff, but also make it work in previous versions.


#2

You could write your package with imports, and use a babel compiler to create an dist/my-package.js file. Be sure to refer dist/my-package.js in your package config. As far as I know, there is no other way to use ES6 in pre 1.3


#3

But if I create it in 1.2 style is still usable in 1.3 i guess. Just that users will need to import from the package the regular exports, is that ok?


#4

Of course that’s okay. If you create a 1.2 package, it will still be usable in 1.3. This version is hugely backwards compatible.