fooloomanzoo / datetime-picker

A minimal picker for date and time for Polymer, that can use the native input
MIT License
78 stars 18 forks source link

ES6 with Polymer 2 #67

Closed brettpostin closed 4 years ago

brettpostin commented 4 years ago

I'm currently using v2.7.10, however we are dropping support for IE11 and with it removing transpilation to es5. Everything is going straight to es6.

However this causes issues using this version of the element as (i believe) it uses es5 class declarations. This requires the custom-elements-es5-adapter which then causes conflicts when mixing in es6 classes.

I can see v3.x+ is now in es6 modules, however it is based on Polymer 3 and we aren't in a position to move from Polymer 2 at this time.

So my questions are:

  1. can you see of a way of using v2.x with es6 classes?
  2. if not, do you have any other suggestions for working with polymer 2 + es6?

I'm thinking of forking the v3 branch and downgrading to polymer 2. Do you see many issues in doing this?

brettpostin commented 4 years ago

Please ignore this issue, I have found some additional transpilation in our toolchain that was converting these elements to es5. I have removed that and all works fine.