crossecore / crossecore-generator

Code generator for Java, C#, TypeScript and Swift
Apache License 2.0
12 stars 8 forks source link

Apply anti dependency cycles pattern #29

Closed schwichti closed 3 years ago

schwichti commented 3 years ago

Refactor the generated typescript code (and the ecore runtime) to use this pattern: https://medium.com/visual-development/how-to-fix-nasty-circular-dependency-issues-once-and-for-all-in-javascript-typescript-a04c987cf0de. The DependencyManager should topologically sort the dependencies and generate an index.ts file with the imports in the right order.

schwichti commented 3 years ago

The mentioned pattern won't work for cyclic dependencies how they are in EMF. Need to stick to madge and resolve cyclic dependencies by hand.