This can be done with a custom eslint rule.
The standard format proposed in T224429 is something along these lines:
// The following messages can be used here: // * msg:visualeditor-table-format-data // * msg:visualeditor-table-format-header mw.msg( 'visualeditor-table-format-' + style );