S
S
Sun_Day2020-06-22 11:17:14
Angular
Sun_Day, 2020-06-22 11:17:14

Is it possible to disable absolute paths in tsconfig or tslint?

A question. Is it possible and how to make the linter throw an error at the application start stage, in which it would point to absolute paths when importing (src/app/component/component) as invalid?

Thank you.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Aetae, 2020-06-22
@Sun_Day

Tslint: import-blacklist . Eslint: no-restricted-imports .
"import-blacklist": [true, ["^src/.*"]]

"no-restricted-imports": ["error", {"patterns": ["src/*"]}]

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question