Improve naming and linter checks in the new UI codebase
simstoykov opened this issue · comments
Environment
- I followed the tutorial for setting up a dev environment.
- I'm developing in VScode, with the
ms-vscode.vscode-typescript-tslint-plugin
plugin installed, versionv1.2.2
- The issue is with the new UI codebase:
grr/server/grr_response_server/gui
. I haven't explored the rest of the code.
Describe the issue
There are a few tslint warnings that show up consistently across components. The ones that I've noticed are:
- Some component selectors do not have a special prefix (e.g. to make them distinct from 3rd-party components). I get the following warning:
The selector should be prefixed by "app" (https://angular.io/guide/styleguide#style-02-07) (component-selector)tslint(1)
. If the component doesn't have dashes in the name like the timestamp component the exact error is:The selector should be kebab-cased and include a dash (https://angular.io/guide/styleguide#style-05-02) (component-selector)tslint(1)
- Some component classes don't have a
Component
suffix, which gives the following warning:The name of the class ClientDetails should end with the suffix Component (https://angular.io/styleguide#style-02-03) (component-class-suffix)tslint(1)
This is not a complete list, and there are probably more tslint warnings.
Shouldn't those warnings be checked in the CI?