[pbs-devel] [PATCH proxmox-backup 10/23] ui: add removable datastore creation support

Lukas Wagner l.wagner at proxmox.com
Tue Sep 19 15:38:24 CEST 2023



On 9/15/23 08:54, Hannes Laimer wrote:

> +			    change: function(checkbox, newValue) {
> +				const inputPanel = checkbox.up('inputpanel');
> +				const pathField = inputPanel.down('[name=path]');
> +				const uuidField = inputPanel.down('[name=backing-device]');
> +

To quote our JS style guide [1]:
   Avoid using const for everything, but rather in the sense of
   constants. JavaScript is to dynamic for it to provide actual benefits
   if used as default.

... So maybe rather use `let` :). Also applies to some of the following 
commits.

[1] https://pve.proxmox.com/wiki/Javascript_Style_Guide#Variables

-- 
- Lukas





More information about the pbs-devel mailing list