NetPad
NetPad copied to clipboard
Add semantic model to SyntaxTree visualizer
Fixes #229
Add Semantic Model to SyntaxTree visualizer.
-
CodeController.cs
- Add a new endpoint to retrieve the semantic model for a given script.
- Use
ICodeAnalysisService
to get the semantic model. - Return the semantic model as a JSON result.
-
CodeAnalysisService.cs
- Add a new method
GetSemanticModel
to retrieve the semantic model for a given code. - Use
CSharpCompilation
to get the semantic model.
- Add a new method
-
ICodeAnalysisService.cs
- Add a new method
GetSemanticModel
to the interface.
- Add a new method
-
syntax-tree-view.ts
- Add a new method to load the semantic model.
- Update the UI to display semantic model information.
- Cache the semantic model along with the syntax tree.
-
syntax-tree-view.html
- Add new elements to display semantic model information.