electricessence / TypeScript.NET

A JavaScript-Friendly .NET Based TypeScript Library (Moved)
https://github.com/electricessence/TypeScript.NET-Core
Other
251 stars 36 forks source link

exports is not defined #66

Closed Shekesh closed 7 years ago

Shekesh commented 7 years ago

I'm using your Linq library as a native ES6 module in Electron (typescript-dotnet-es6). The module gets extracted by rollup.js. The import looks like import Enumerable from 'typescript-dotnet-es6/System.Linq/Linq'; Electron / chromium throws the error Uncaught ReferenceError: exports is not defined The source of the error is in https://github.com/electricessence/TypeScript.NET/blob/3c5be8a3632d9e54532aed324459d59f283aca6b/dist/es6/System/Environment.js#L29 When I delete Object.freeze(exports) everything works fine.

electricessence commented 7 years ago

Investigating...

electricessence commented 7 years ago

I see...

electricessence commented 7 years ago

Will need a bit of time to fix as TS has somehow become wildly incompatible with the code I have. It is an easy fix, it's just not easy to fix right this second. I have branches in place, but they won't compile. :(

electricessence commented 7 years ago

Ok. This is fixed. Please verify at your leisure. Latest is now: 4.9.8

Shekesh commented 7 years ago

I can confirm it is fixed. Thank you very much :smile: