using constraint -> type* and type -> alias* mappings at js side