Valid JS Identifier

Valid JS Identifier

Make sure that all message IDs are valid JavaScript identifiers.

valid_js_identifier_id.jpg

#What does this rule do?

Enforces that all message ids are valid JavaScript identifiers. It also excludes any reserved JS keywords. You can read more about valid JS identifiers here.

#Manual setup

Besides installing the lint rule through manage.inlang.com you could also configure it manually.

#Settings

Type:

type MessageLintRuleLevel = "error" | "warning"

Example in the settings.json:

{
    // other configuration
    "messageLintRuleLevels": {
		"messageLintRule.inlang.validJsIdentifier": "error",
	}
}

The default level is warning

Publisher

inlang

inlang

License

Apache-2.0