NatLibFi / Annif

Annif is a multi-algorithm automated subject indexing tool for libraries, archives and museums.
https://annif.org
Other
196 stars 41 forks source link

Use a JS framework for the web application #244

Open kinow opened 5 years ago

kinow commented 5 years ago

Hi,

Maybe a framework like VueJS could be used instead of HTML + JS (JQuery + Bootstrap). I think the use case so far is perfect for a small app as Annif is right now.

But for #24 and onward, I think having a framework could be helpful. For example, one line is enough to add Vue.JS to the project (using their CDN distro). And after that we don't need webpack, vue-cli, npm, etc. We can just use their CDN version initially, and adopt the rest of their ecosystem if necessary.

I believe this is a compromise between relying heavily on a framework (which happens when you adopt something like React or Angular) and relying on pure JS with JQuery (which later can get complicated when the app grows).

Besides, this could be a good testbed for later use of similar technique in Skosmos :slightly_smiling_face:

osma commented 5 years ago

PR #245 provides the first steps for this.

osma commented 5 years ago

Changing the milestone as 0.39 is going to be released soon but all of the developments in this issue are unlikely to be finished by then.

juhoinkinen commented 1 year ago

In PR #646 jQuery was replaced with the Axios library.

osma commented 1 year ago

Is there anything that still needs to be done, or can we close this issue?

The Web UI is already using a static copy of Vue.js (and Axios and Bootstrap, but not jQuery anymore).

Forgive my ignorance, but what is the advantage of using vue-cli or Webpack? Or declaring dependencies? Would that mean that we could get a leaner Vue for our purposes?