File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
tasks/website/src/linter/rules Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -196,10 +196,16 @@ fn how_to_use(rule: &RuleTableRow) -> String {
196196 format ! ( "{}/{}" , normalized_plugin_name, rule. name)
197197 } ;
198198 let is_default_plugin = is_default_plugin ( plugin) ;
199+ let is_tsgolint_rule = rule. is_tsgolint_rule ;
200+
201+ let type_aware_flag = if is_tsgolint_rule { "--type-aware " } else { "" } ;
202+
199203 let enable_bash_example = if is_default_plugin {
200- format ! ( r"oxlint --deny {rule_full_name}" )
204+ format ! ( r"oxlint {type_aware_flag} --deny {rule_full_name}" )
201205 } else {
202- format ! ( r"oxlint --deny {rule_full_name} --{normalized_plugin_name}-plugin" )
206+ format ! (
207+ r"oxlint {type_aware_flag}--deny {rule_full_name} --{normalized_plugin_name}-plugin"
208+ )
203209 } ;
204210 let enable_config_example = if is_default_plugin {
205211 format ! (
You can’t perform that action at this time.
0 commit comments