canhorn / EventHorizon.Blazor.TypeScript.Interop.Generator

This project is a Blazor Interop C# Generator, has a sample against the BabylonJS library.
https://wonderful-pond-05f7b3b10.azurestaticapps.net/
MIT License
132 stars 19 forks source link

New NodeJS AST Parser Implementation #36

Closed canhorn closed 3 years ago

canhorn commented 3 years ago

Using NodeJS to parse the TypeScript it should now generate a better AST when using modern TS features. Includes a flag to switch between the old (good enough for most scenarios) and the new modern parser. Using the abstraction the generator can select the parser from options, defaults to old parser.

The tests are copies of the Sdcb tests, should cover the most if not all the code generation scenarios.

codecov-io commented 3 years ago

Codecov Report

Merging #36 (25d0cb5) into main (00f2a84) will decrease coverage by 0.47%. The diff coverage is 96.74%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main      #36      +/-   ##
==========================================
- Coverage   98.83%   98.36%   -0.48%     
==========================================
  Files          76       89      +13     
  Lines        3189     4048     +859     
  Branches      285      374      +89     
==========================================
+ Hits         3152     3982     +830     
- Misses         20       35      +15     
- Partials       17       31      +14     
Impacted Files Coverage Δ
...pt.Interop.Generator/GenerateCachedEntityObject.cs 100.00% <ø> (ø)
....TypeScript.Interop.Generator/GenerateClassShim.cs 100.00% <ø> (ø)
...terop.Generator/Identifiers/AliasTypeIdentifier.cs 55.26% <ø> (-44.74%) :arrow_down:
...erator/Identifiers/AliasTypeStatementIdentifier.cs 100.00% <ø> (ø)
...nterop.Generator/Identifiers/ArgumentIdentifier.cs 100.00% <ø> (ø)
...p.Generator/Identifiers/ArrayResponseIdentifier.cs 100.00% <ø> (+10.52%) :arrow_up:
...nterop.Generator/Identifiers/EnumTypeIdentifier.cs 100.00% <ø> (ø)
...tor/Identifiers/InterfaceResponseTypeIdentifier.cs 98.71% <ø> (ø)
...op.Generator/Identifiers/NullableTypeIdentifier.cs 100.00% <ø> (ø)
...p.Generator/Identifiers/PrimitiveTypeIdentifier.cs 100.00% <ø> (ø)
... and 67 more

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 00f2a84...25d0cb5. Read the comment docs.

github-actions[bot] commented 3 years ago

Azure Static Web Apps: Your stage site is ready! Visit it here: https://wonderful-pond-05f7b3b10-36.centralus.azurestaticapps.net

github-actions[bot] commented 3 years ago

Azure Static Web Apps: Your stage site is ready! Visit it here: https://wonderful-pond-05f7b3b10-36.centralus.azurestaticapps.net

github-actions[bot] commented 3 years ago

Azure Static Web Apps: Your stage site is ready! Visit it here: https://wonderful-pond-05f7b3b10-36.centralus.azurestaticapps.net

github-actions[bot] commented 3 years ago

Azure Static Web Apps: Your stage site is ready! Visit it here: https://wonderful-pond-05f7b3b10-36.centralus.azurestaticapps.net

github-actions[bot] commented 3 years ago

Azure Static Web Apps: Your stage site is ready! Visit it here: https://wonderful-pond-05f7b3b10-36.centralus.azurestaticapps.net

canhorn commented 3 years ago

The drop of -0.48% is from the cache section not getting covered with the added Unit Tests added.