Enteee / plantuml-parser

Parse PlantUML with JavaScript or TypeScript
https://duckpond.ch/category/plantuml-parser
Apache License 2.0
138 stars 33 forks source link

Initial basic parsing functionality for Stdlib C4 #74

Closed dgassma closed 2 years ago

dgassma commented 2 years ago

I am in the need of parsing plantuml's stdlib C4. Since it was not yet part of your project, I started to add the basic parsing functionality. Before I continue adding the missing parts & pieces I want to make sure, that the structure and code meet your expectations.

Looking forward to get feedback.

Enteee commented 2 years ago

Hello and thank you for your contribution. This is great and the quality looks good :+1:

But to be honest I am a bit unsure about how to proceed with this. Fact is, that there are a lot projects extending the base plantuml language with custom syntax. Sadly, the plantuml pre-processor allows for this.

But I if I start merging such dialects into the base plantuml grammar - i will end up having to maintain all of them. I also have limited time and I don't think that this is feasible. I can not maintain this.

So on one hand, i would like to merge this because it is a great addition to the parser. On the other hand, i see great problems that might come from this..

I need a bit of time to think about this. Sorry...

dgassma commented 2 years ago

Thanks for the feedback.

I totally understand your concerns. My point of view is, that you do not lose anything if you add it. Why? My plan is to provide an implementation for the official stdlib C4 in v2.4.0. If something changes in the future and someone is in need for a fix, that person can provide that fix. Sure, you as the owner has to look over it. But to be honest, I do not think that there are so many changes in the future.

Anyway, take from your message, that the structure and the way I started implementing it, is okay for you, so I am going to continue. Since it will not be ready in the next days, you got the time to think about it.

Enteee commented 2 years ago

ok i am happy to merge this. Especially since all the parts in the grammar seems to be prefixed properly. I like that a lot.

Enteee commented 2 years ago

thank you for your contribution. :rocket: