question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

How to use plugins and locales now?

See original GitHub issue

So, uhh. How should I use rangePlugin and locales now without Webpack? I just want to get source code and include it in my page via <script></script> but I’m not able to.

Uncaught ReferenceError: exports is not defined at flatpickr.rangePlugin.js:2

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
chmlncommented, Oct 10, 2017

Hi all,

As of v4.0.1, out now, locales and plugins are UMD modules. The window.exports hack is no longer necessary.

This means that they can be consumed via both script tags or imports painlessly.

Its my goal to make flatpickr as easy to use as possible for end-users, and complicating things was not in my plans - its rather just a side effect of such a major overhaul, but it is for the better.

Thank you for your patience.

1reaction
salihsagdilekcommented, Oct 10, 2017

me too have same issue, localization is broken. and im analyzed and seen localization names changed

  const flatpickr = require('flatpickr')
  import { tr } from 'flatpickr/dist/l10n/tr'
  flatpickr.localize(tr)

new code

  const flatpickr = require('flatpickr')
  import { Turkish } from 'flatpickr/dist/l10n/tr'
  flatpickr.localize(Turkish)

and everythings ok 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

Install and Enable the Custom Locale Plugin - PKP Docs
Go to Settings > Website > Plugins; Find the Custom Locale Plugin in the list of Installed Plugins (if it is not listed...
Read more >
How to Install, Add, and Use WordPress Plugins - HubSpot Blog
The simplest way to add plugins is by searching for your desired plugin in your WordPress dashboard and installing with a click. The...
Read more >
How do I add a VST plugin into a Windows DAW? - Sweetwater
Click Audio Plug-ins, select plug-in and click Enable. Return to top. How to use VST plug-ins. Now that you know how to add ......
Read more >
Locales Plugin - MariaDB Knowledge Base
If you installed the plugin by providing the --plugin-load or the --plugin-load-add options in a relevant server option group in an option file,...
Read more >
Use Plugins - fastlane docs
Find a plugin. Head over to Available Plugins for a list of plugins you can use. List all available plugins using fastlane search_plugins....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found