13af6ab5fSopenharmony_ci# Import assertions are not supported 23af6ab5fSopenharmony_ci 33af6ab5fSopenharmony_ciRule ``arkts-no-import-assertions`` 43af6ab5fSopenharmony_ci 53af6ab5fSopenharmony_ci**Severity: error** 63af6ab5fSopenharmony_ci 73af6ab5fSopenharmony_ciArkTS does not support import assertions because in the language import is a 83af6ab5fSopenharmony_cicompile-time, not a runtime feature. So asserting correctness of imported APIs 93af6ab5fSopenharmony_ciin runtime does not make sense for the statically typed language. Use ordinary 103af6ab5fSopenharmony_ci``import`` syntax instead. 113af6ab5fSopenharmony_ci 123af6ab5fSopenharmony_ci 133af6ab5fSopenharmony_ci## TypeScript 143af6ab5fSopenharmony_ci 153af6ab5fSopenharmony_ci 163af6ab5fSopenharmony_ci``` 173af6ab5fSopenharmony_ci 183af6ab5fSopenharmony_ci import { obj } from "something.json" assert { type: "json" } 193af6ab5fSopenharmony_ci 203af6ab5fSopenharmony_ci``` 213af6ab5fSopenharmony_ci 223af6ab5fSopenharmony_ci## ArkTS 233af6ab5fSopenharmony_ci 243af6ab5fSopenharmony_ci 253af6ab5fSopenharmony_ci``` 263af6ab5fSopenharmony_ci 273af6ab5fSopenharmony_ci // Correctness of importing T will be checked in compile-time: 283af6ab5fSopenharmony_ci import { something } from "module" 293af6ab5fSopenharmony_ci 303af6ab5fSopenharmony_ci``` 313af6ab5fSopenharmony_ci 323af6ab5fSopenharmony_ci## See also 333af6ab5fSopenharmony_ci 343af6ab5fSopenharmony_ci- Recipe 129: Wildcards in module names are not supported (``arkts-no-module-wildcards``) 353af6ab5fSopenharmony_ci- Recipe 130: Universal module definitions (UMD) are not supported (``arkts-no-umd``) 363af6ab5fSopenharmony_ci 373af6ab5fSopenharmony_ci 38