Closed
Description
I'm not sure if this is valid ES6 code but I'm trying to get this work:
app.ts
import function1, { function2 } from './module1'
function1()
function2()
module1.ts
export default function function1() {
console.log('hej')
}
export function function2() {
console.log('hej')
}
I'm using today's master branch and I get the following error when I compile app.ts
:
error TS2309: An export assignment cannot be used in a module with other exported elements.
An another question, if app.ts
do a namespaced import will I have access to the default function too?
app.ts
import * as module1 from './module1'
module1.function1()
module2.function2()