Run the ESLint static analysis tool on any code that is submitted, to
find possible bugs such as undefined functions and variables. We may
want to adjust the ESLint settings over time, but this seems like a
good start.
This is merged into the previous check-translations.yml action, because
that's also a form of linting. Possibly that could be reimplemented as
an ESLint plugin.
These two seem like bugs but are unclear to me how to fix, so I've added
FIXMEs.
/puter/packages/backend/src/routers/kvstore/clearItems.js
41:32 error 'DB_MODE_WRITE' is not defined no-undef
/puter/packages/backend/src/routers/whoami.js
104:35 error 'db' is not defined no-undef
/puter/src/UI/Settings/UITabSecurity.js
13:13 error 'user' is not defined no-undef
31:13 error 'user' is not defined no-undef
32:70 error 'user' is not defined no-undef
36:30 error 'user' is not defined no-undef
40:82 error 'user' is not defined no-undef
41:83 error 'user' is not defined no-undef
87:41 error 'api_origin' is not defined no-undef
/puter/src/UI/UIWindow2FASetup.js
39:33 error 'api_origin' is not defined no-undef
51:37 error 'api_origin' is not defined no-undef
69:37 error 'api_origin' is not defined no-undef
/puter/src/UI/UIWindowLogin.js
202:73 error 'api_origin' is not defined no-undef
271:73 error 'api_origin' is not defined no-undef
When exiting a window there should be a confirmation if exiting that window will irreversibly destroy work. For example, when you're working on a document and if you exit unsaved changes will be lost.
This doesn't seem to be the case. What work will be irreversibly lost?