So I haven't had time to fully digest this thread, but a couple ideas/notes from me.
* Bootstrap and jquery are pretty large dependancies, are they needed for something specific? or just easier to do development. http://youmightnotneedjquery.com/ is kinda snarky and old, but does have some good points. * if you use a bundler (rollup/webpack/Parcel/etc) + maven-frontend-plugin, you should be able to use npm install and requires, and not worry about other plugins are doing. Out f the box this has the disadvange of larger bundle sizes, but would reduce any friction. Its kinda what the java plugins are doing anyways, where they have seperate classpaths per plugin. * Shared js deps is kinda how we got in the mess of having prototype on every page breaking things. I know there's no up to date official browser matrix, but since plugins have a lot more flexibility when it comes compatibilty, my suggestion is to use more modern javascript and css, and not need all the frameworks that try to support the really old ones, or at least write modern code, but get babel to backport so it doesn't break old browsers, then we wouldn't need jquery as much. Gavin On Thu, Jul 4, 2019 at 2:15 PM Ullrich Hafner <[email protected]> wrote: > I’m not sure if we need so much new modules. For my plugin (and a lot of > other reporter based plugins) I think it would make sense to have just a > couple of them (<10). Bootstrap, jQuery, DataTables, ECharts, Prism, > Fontawesome would be the prominent ones. The dependencies of e.g. bootstrap > would make sense to be packaged into a bootstrap package. > > If I use individual versions per plugin then we get into problems if > several plugins show up on the same page. E.g. the job or build page will > be problematic (they are already since Jenkins core uses some old and not > compatible libs here). I think here it would be much better if we have a > set of JS plugins that would be shared by all plugins (and by Jenkins > core). > > > > Am 03.07.2019 um 14:04 schrieb Jack Shen <[email protected]>: > > For the idea that you had like a standalone plugin to provide dependency, > I ever thought about that before. > However there might be too many dependencies and too many versions for > each dependency. > So I think maybe it's better to use a specific version of the library you > use in your repo. > > And if you are interested in the new way we're trying in working hours > plugin, we could share some idea with you on each Thursday 13:00(UTC) > > Jack Shen <[email protected]> 于 2019年7月3日周三 19:38写道: > >> And I'm also wondering that would it be better if we switch to another >> solution like webpack? You know, using inline js libraries is not recommend >> in some conditions, so why not make some changes and try something new? >> >> Jack Shen <[email protected]> 于 2019年7月3日周三 19:33写道: >> >>> Hi Ullrich, you are not alone on this question, because I think we have >>> some similar requirements on using external libraries. >>> >>> I'm currently working on my GSoC project, in which I tried using react >>> with success. >>> >>> What we have done in the our plugin working-hours-plugin >>> <https://github.com/ShenJack/working-hours-plugin> is integrating the >>> file built by webpack into jelly file. >>> >>> Actually, I has ever referred to the Warning NG Plugin, I agreed and >>> learned some methods which you are using on fixing the incompatibility with >>> prototype.js. >>> >>> 在 2019年7月3日星期三 UTC+8上午3:50:47,Ullrich Hafner写道: >>>> >>>> >>>> >>>> > Am 02.07.2019 um 16:12 schrieb Jesse Glick <[email protected]>: >>>> > >>>> > Read >>>> > >>>> > https://github.com/jenkinsci/js-libs >>>> > >>>> > and you will know more than I. >>>> > >>>> >>>> Yes, I tried to use that approach already without success. I got stuck >>>> somewhere in the middle and nobody is here who can help on UI issues >>>> anymore :-( Seems that all the UI super-heroes have left Jenkins... >>> >>> >>> -- >>> You received this message because you are subscribed to a topic in the >>> Google Groups "Jenkins Developers" group. >>> To unsubscribe from this topic, visit >>> https://groups.google.com/d/topic/jenkinsci-dev/VOULzB0GozQ/unsubscribe. >>> To unsubscribe from this group and all its topics, send an email to >>> [email protected]. >>> To view this discussion on the web visit >>> https://groups.google.com/d/msgid/jenkinsci-dev/18f2590a-7d65-4637-93af-c20accb02c5d%40googlegroups.com >>> <https://groups.google.com/d/msgid/jenkinsci-dev/18f2590a-7d65-4637-93af-c20accb02c5d%40googlegroups.com?utm_medium=email&utm_source=footer> >>> . >>> For more options, visit https://groups.google.com/d/optout. >>> >> > -- > You received this message because you are subscribed to the Google Groups > "Jenkins Developers" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/jenkinsci-dev/CAPCUAQsvyCWF81HS%2B0bwrEnZdymoNkigeF8%3DBB_PZaJkUcsiGA%40mail.gmail.com > <https://groups.google.com/d/msgid/jenkinsci-dev/CAPCUAQsvyCWF81HS%2B0bwrEnZdymoNkigeF8%3DBB_PZaJkUcsiGA%40mail.gmail.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > > > -- > You received this message because you are subscribed to the Google Groups > "Jenkins Developers" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > To view this discussion on the web visit > https://groups.google.com/d/msgid/jenkinsci-dev/DD64433C-F29F-40BA-AB09-84BFD43208A6%40gmail.com > <https://groups.google.com/d/msgid/jenkinsci-dev/DD64433C-F29F-40BA-AB09-84BFD43208A6%40gmail.com?utm_medium=email&utm_source=footer> > . > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Jenkins Developers" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jenkinsci-dev/CAG%3D_DuvXki4OUu9AxXEmm8sB7JmRtGfMuvv4wby_UASqv%3D%2BqzA%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
