ItamarWMDE created this task.
ItamarWMDE added projects: Wikidata, Mismatch Finder (Mismatch Finder - sprint
4).
TASK DESCRIPTION
As we want to leverage WiKit as the design system of this project. We would
need to set up Vue as a Single Page application within our Laravel project.
With Laravel, we can set up Vue in one of two ways:
1. As a standalone Vue application (which would live in the `resources/js`
folder, most probably). This would mean we would need to:
- Implement a client side routing Library (to transition from "page" to
"page"). **//Normally this is done with Vue Router
<https://router.vuejs.org/>.//**
- Implement a state management library, to ensure the application state is
derived from, and reflects the REST API state. **//In WMDE we most commonly use
Vuex <https://vuex.vuejs.org/>//**.
- Make sure that our REST API Routes are ready before developing features
in the client side **OR**
- Find a way to mock data for the client side, for these cases where the
API is not ready yet. **//Can be done with something along the lines of
Mirage.js <https://miragejs.com/> or JSON Server
<https://github.com/typicode/json-server>//**
2. As a vue application that is managed by, and consumes responses from, an
Inertia.js <https://inertiajs.com/> Implementation. This seems to be the
preferred Laravel approach, but has some downsides:
- PRO: Much less setup, while we might still need a state management
library, we won't require it for routing, and we can implement it on a per
needed basis.
- PRO: Less context shifting, we keep writing web routes and controllers
like we have done so far, but instead of responding with a view, we will
respond with an Inertia page.
- PRO: Closer to our Database implementation, so we could potentially
implement features like batch editing, without having to implement them in the
REST API.
- CON: This full couples our client side application with our backend
implementation. Meaning that if we decided to switch from a Laravel server to a
python server one day, we would also have to put in work to extract the client
side app out of the project.
**//In addition to these considerations, another factor that we should
consider is whether to use TypeScript <https://www.typescriptlang.org/> or
Vanilla ES+. TypeScript seems to be the preferred flavor in WMDE, which would
add a bit of setup overhead to both of the above possible setups.//**
Thus, we need to reach a decision, as a team, on which technologies to
implement, and then perform the groundwork so that we can start developing Vue
components.
AC:
[ ] The team has decided and documented the vue stack to use for our client
side app.
[ ] The chosen stack is set up with one example page and one example
component.
TASK DETAIL
https://phabricator.wikimedia.org/T288046
EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/
To: ItamarWMDE
Cc: Aklapper, ItamarWMDE, karapayneWMDE, Invadibot, maantietaja,
Mattia_Capozzi_WMDE, Akuckartz, Nandana, Lahi, Gq86, GoranSMilovanovic,
QZanden, LawExplorer, _jensen, rosalieper, Scott_WUaS, Wikidata-bugs, aude,
Mbch331
_______________________________________________
Wikidata-bugs mailing list -- [email protected]
To unsubscribe send an email to [email protected]