Skip to content

Latest commit

 

History

History
31 lines (24 loc) · 1.62 KB

directives.md

File metadata and controls

31 lines (24 loc) · 1.62 KB

Directives

You can configure Aspect CLI using directives, which are just specially-formatted comments in BUILD files that govern behavior of the tool when visiting files within the Bazel package rooted at that file.

JavaScript

JavaScript directives follow the same format as gazelle.

Directives specific to JavaScript (and TypeScript) are as follows:

Directive Default value Param(s)
js enabled enabled|disabled
js_generation_mode directory none|directory
js_pnpm_lockfile pnpm-lock.yaml lockfile
js_ignore_imports glob
js_resolve glob target
js_validate_import_statements true true|false
js_project_naming_convention {dirname} name
js_tests_naming_convention {dirname}_tests name
js_files **/*.{ts,tsx} glob
js_test_files **/*.{spec,test}.{ts,tsx} glob
js_npm_package_target_name {dirname} ...

All JavaScript directives are specified via gazelle such as:

# gazelle:js enabled