Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

timezone string values results in parseZone() and clone() not a function error . #156

Closed
DevIsShortForDevil opened this issue May 12, 2021 · 1 comment

Comments

@DevIsShortForDevil
Copy link

Hi , I'm using the timezone feature with string prop values . but doing this results in
talkhabi-vue-datepicker-errors-1 on load . it works fine with Booleans , but also has these errors with functions.
here are the props on the datepicker :

<VuePersianDatetimePicker
      v-model="internalValue"
      :timezone="'+04:30'"
      clearable
      :locale="'fa,en'"
      :locale-config="{
          fa: {
            displayFormat: this.displayTime ? 'jYYYY/jMM/jDD HH:mm' : 'jYYYY/jMM/jDD',
            lang: { label: 'شمسی' },
          },
          en: {
            displayFormat: this.displayTime ? 'YYYY/MM/DD HH:mm' : 'YYYY/MM/DD',
            lang: { label: 'Gregorian' },
          },
        }"
      format="YYYY-MM-DD HH:mm:ss"
      :type="'datetime'"
    /> 

I checked the source code but couldn't find anything and really appreciate it if you could look into this.

@DevIsShortForDevil
Copy link
Author

I think this will be solved if you import moment from 'moment-timezone' or a jalaali version of it instead of 'moment' or 'moment-jalaali'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant