context-mapper-dsl
context-mapper-dsl copied to clipboard
Allow for linking concrete code
For me, documentation should offer links to the code. For example, the "implementation" of an Entity should be linkable.
GitHub allows for copying permalinks. They could be used: https://github.com/JabRef/jabref/blob/f3283637b3163e9a736df8354d28c5fc3297a824/src/main/java/org/jabref/model/entry/BibEntry.java#L56
With that, an interested reader could directly jump to the code.
- Advanced (follow-up) feature: Allow for jumping to the code in the favorite IDE.
- Advanced (follow-up) feature: Alarm the user if the code changes and the domain model should be changed. https://swimm.io/ demonstrates how this could work.
Hi @koppor
Thanks for your input!
With "documentation" you mean a CML model in this context, right? You would like to be able to jump from the CML editor, for example by clicking on a modeled entity, to the implementation of the corresponding entity? Interesting request, but also very tricky to implement. I wonder whether a solution just for GitHub would help many users, as many probably don't work in an open-source (GitHub) context. Jumping to the corresponding implementation directly in the IDE would probably be even better then leaving the IDE and go to the browser.
Advanced (follow-up) feature: Alarm the user if the code changes and the domain model should be changed.
This actually already works with our ArchUnit extension: Validating the Implementation against the Model I use it in my projects so that if the code changes the build will error unless I adjust the domain model accordingly. But of course, you only realize it after you have run the build or get notified by your CI that the build is broken. A warning directly in the IDE would be nicer; I agree :)