Page MenuHomePhabricator

Folder structure for assets built by Webpack should be separated from standard ResourceLoader assets
Closed, DeclinedPublic2 Estimated Story Points

Description

This follows up the conversation in T257647#6431761

The folder structure is very confusing. The resources folder is typically used for assets directly shipped to the end user, however resources/skins.vector.search/App.vue and resources/skins.vector.search/index.js are assets that are built via webpack and shipped via a file in resources/dist.

In other repos where we've mixed webpack and ResourceLoader (e.g. MobileFrontend and Popups) we use a src folder to distinguish these files from the rest of Vector.

Having the resources and source files mixed can be confusing to developers not familiar with using webpack and is inconsistent with our other repos

suggested layout

  • resources/skins.vector.search moved to src/skins.vector.search
  • webpack configuration updated

acceptance criteria

  • It should be logical from the names of dist which ResourceLoader module name they are shipped with (this appears to currently be the case)
  • JS built via webpack should be clearly separated from JS that is not
  • The resources folder should only contain files that are shipped via ResourceLoader and listed in skin.json

Event Timeline

Jdlrobson triaged this task as Medium priority.Sep 17 2020, 11:06 PM
ovasileva set the point value for this task to 2.Sep 28 2020, 5:15 PM

This task is medium priority but seems smallish and mostly independent of the other work. It would be a good starter task.

Blocked on the decision of the working group meeting this week.

The current recommendation of the working group that met last week is to not use a build step in Vector so this task is not necessary any more. We will be deleting the search feature branch.