wwilsman / Datepicker.js

Datepicker.js
http://wwilsman.github.io/Datepicker.js
MIT License
39 stars 20 forks source link

umd #11

Closed taoqf closed 6 years ago

taoqf commented 6 years ago

it seems should be

  if (typeof define === 'function' && define.amd) {
    define('Datepicker', factory);
  } else if (typeof exports === 'object') {
    module.exports = factory;
  } else {
    root.Datepicker = factory;
  }

I find there is too many changes between the version in npm and github, and could not help to fix this.

another bug: it seems should use relative instead of absolute in css

.datePicker.has-popup .datePicker__container {
    position: relative;
}
wwilsman commented 6 years ago

Hey @taoqf, sorry for taking so long to respond! For some reason, I'm not getting notifications for this repo.

The UMD part is taken care of by webpack (though I plan on switching that to rollup soon). Maybe once I make that switch, it will take care of that.

With the CSS bug, I'm not sure if that is relevant anymore. I can't find has-popup in the source CSS files.

You mentioned npm and github being different, I plan on making a new release after switching to rollup and integrating your typescript support. So that should remedy the version differences.

taoqf commented 6 years ago

@wwilsman thanks, I will try the latest version if I have time.

wwilsman commented 6 years ago

Just released v0.1.1 which includes typescript definition and now uses rollup

taoqf commented 6 years ago

Why not use datepicker.js any more? I find the name changed Datepicker.js.

taoqf commented 6 years ago

Would this work?