refactors js items-processing.