typescript1.5 - TypeScript destructuring alias import? -


i use namespaces/modules application. have large application broken several smaller "modules". compiled together, have references @ times. if need access module x.y module z can using x.y. howevever, don't want keep referencing x. there anyway can destructure x aliased names? example (this doesn't work, hence question):

import {y,a,b} = x; 

instead of:

import y = x.y; import = x.a; import b = x.b; 

is there similar can simplify import aliasing of internal modules?

is there similar can simplify import aliasing of internal module

if members of module importing not modules (or type) import not work. use var instead:

module x{  // stuff } var {y,a,b} = x; 

Comments

Popular posts from this blog

javascript - Using jquery append to add option values into a select element not working -

Android soft keyboard reverts to default keyboard on orientation change -

Rendering JButton to get the JCheckBox behavior in a JTable by using images does not update my table -