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

Distribute a version of FullCalendar with all plugins #4566

Open
arshaw opened this issue Mar 20, 2019 · 5 comments
Open

Distribute a version of FullCalendar with all plugins #4566

arshaw opened this issue Mar 20, 2019 · 5 comments
Milestone

Comments

@arshaw
Copy link
Member

@arshaw arshaw commented Mar 20, 2019

@toxpal raises a good point about how annoying it is to need to load many different plugin files, whereas in v4 only 1 JS and CSS file were required. Users of a Webkit/Rollup build environment probably appreciate the division into plugins, because their build environment does the bundling for them, and they can save on filesize, but for people who initialize via script tags and browser globals, this can definitely be annoying.

Something that is annoying for users of both techniques is that they need to manually include all required CSS files. This low-tech solution was decided in this issue.

Something else that doesn't make a whole lot of sense is how the plugin files are used from a CDN (see the "CDN" section on the Downloads page). The whole reason people use CDNs is to make their sites load faster, but if they need to load each individual plugin files (both JS and CSS), it sort of defeats the point. They could end up with ~8 requests.

What I'm getting at is... maybe we should offer a build of FullCalendar that includes ALL of the plugins by default. It wouldn't be necessary to feed them into the plugins array. Everything would just work. Of course, this single JS/CSS would be larger.

I'm not exactly sure how this would work with Scheduler's plugins.

@toxpal

This comment has been minimized.

Copy link

@toxpal toxpal commented Mar 21, 2019

I like the idea of having multiple versions - barebone (in case someone wants to manually include only files they need), and full one (where all the functions just work).

Not because I need absolutely all the functions for every instance of calendar I load in my apps (I really don't), but because I optimize my apps as much as possible. And for me, loading only 2 files (1 JS + 1 CSS), even if they are bigger in size, makes much more sense (in terms of performance) than making extra HTTP requests every time I need some additional feature.

Personally, I like how CKEditor devs solved this issue - they offer a few versions, so user can choose how many features he wants and download smaller/bigger package - https://ckeditor.com/ckeditor-4/download/

In other hand, it requires extra efforts to create separate packages and maintain them. I guess it's the main reason why they simply bundled all the stuff and offer one package (that just works out of the box) in v5 - https://ckeditor.com/ckeditor-5/download/

@arshaw

This comment has been minimized.

Copy link
Member Author

@arshaw arshaw commented Mar 21, 2019

For CKEditor 5, they're putting the onus on the developer to make their own custom build via ES6 modules. That's what FullCalendar is doing as well.

You should try using Webpack! It will get you a small filesize AND only one JS/CSS file.
https://fullcalendar.io/docs/initialize-es6

@johndevman

This comment has been minimized.

Copy link

@johndevman johndevman commented Apr 15, 2019

@arshaw The difference between CKEditor and FullCalendar (from my understanding) is that with CKEditor you actually make a build that you can include and then initialise on a DOM element in the web browser. So you kinda exposing an API you can utilise in the browser. In the docs presented above you'll need to render the Calendar to an DOM element in the build. I'm definitely ++ on using ES6 to make a own build If I can, but I need to use the API in the browser, to determine on which the element should be rendered at. But currently, I need to manually download a .zip to accomplish this desired behaviour, or is there something I'm overlooking.

@arshaw

This comment has been minimized.

Copy link
Member Author

@arshaw arshaw commented Feb 5, 2020

If you're curious to know, this will be included in v5 (currently in-development)
blog post: https://fullcalendar.io/blog/2020/02/changes-in-the-upcoming-v5

@toxpal

This comment has been minimized.

Copy link

@toxpal toxpal commented Feb 5, 2020

Sounds great. I guess it won't be compatible with Bootstrap 3? :)

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

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.