-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Plugins dependency #456
Comments
Maybe we could add a subfolder And import the duplicated functions from this folder. Like 1st one is also reasonable. |
It's fine for me. I'll try this, and if there are any changes, I'll change my PR |
Sorry, but I don't see why grouping shared methods along some plugins, might affect theirs typescript definiton. I mean, what I've understood is, under the plugin folder will be a
But they won't be exported as a plugin, but used by the plugins that will be exported. Am I misunderstanding or missing something? |
No, you are correct. What I really mean is as we are updating plugin's folder design, why not just consider the related issue that need change folder as well. Maybe we can fix both. |
Ok, makes sense. I'll mention this on the other issue and see what comes out |
I'm trying to create a new plugin to retrieve how many weeks has an specific year.
The algorithm relies on methods that are already created in others plugins (
daysInYear
,isLeapYear
,dayOfYear
). How we should treat this dependency?I see various options
weeksInYear
in this case) also includes the other plugins. The worst case scenario would be that some plugins are loaded twice. If this would be the case, a warning message could be shown in the console saying something likeThe plugin .... has been loaded twice
.This plugins .... must be included in order to this plugin works
Since the main goal of this lib is to remain small, my preferred option is the 1st one. Any thoughts?
The text was updated successfully, but these errors were encountered: