Widgets need two files in order to work : app.css and app.js Add those two files to your html head.
The CSS file of the DSE is expected to be present on the hosting page.
Widgets can now be called directly into the page as custom html elements. Widgets takes a least one parameter indicateur. The value should be a string corresponding to the name of a JSON file available in this repository.
<data-box indicateur="cas_positifs"></data-box>
Require one parameter indicateur
<line-chart indicateur="cas_positifs"></line-chart>
Require one parameter indicateur
<bar-chart indicateur="cas_positifs"></bar-chart>
Require one parameter indicateur
<bar-chart indicateur="cas_positifs"></bar-chart>
Require 2 parameters indicateur1 and indicateur2
<map-chart indicateur="cas_positifs"></map-chart>
Require 1 parameters indicateur
<geo-list></geo-list>
Require no parameter. If included, the change of localisation will trigger the update of every widgets on the same page.
- https://itnext.io/vuidget-how-to-create-an-embeddable-vue-js-widget-with-vue-custom-element-674bdcb96b97
- GitHub - karol-f/vue-custom-element: Vue Custom Element - Web Components' Custom Elements for Vue.js
- https://innovation.enova.com/building-an-embeddable-micro-frontend-with-vue-js/
npm install
npm run serve
npm run build
npm run lint
Webpack should be install with npm install webpack@^4.0.0 --save-dev