What is a `scenegraphObject` (XD 19 API changes)

I’m currently updating the typings for the new XD 19 APIs and encountered a rather peculiar type of Object<scenegraphObject> (cf., e.g., https://github.com/AdobeXD/plugin-docs/blob/038aa2d7b9c141c6d961a9726089523ca27647c4/reference/interactions.md) :wink:.

Now to my question/request/whatever (me not knowing exactly what of the said things this is also making me write this here and not in the GitHub issues section):

What is this type? Is it just a SceneNode? If so: Why not just write that? If not: What is it and how am I supposed to be able to implement an undocumented class of scenegraphObject (which doesn’t even match any naming conventions established in the docs, leaving me no clues what it could be).

Also: Until now, all typedefs I know of have been UpperCamelCase (Point and Bounds in scenegraph, ColorAsset etc. in assets). Why now have typedefs for interactionData and transitionData in another convention? This all leaves me (rather early since I have to understand it for the typings) and – of course – other developers having to do detective work to possibly find out if there are differences, what they are, etc.

All in all, I primarily want to ask what said type is (the inconsistencies are – for my work at the typings – annoyances, but easy to implement).

However, I would also like to request to keep the consistency in the docs (or, of course, document the reasoning for inconsistencies) since it is this consistency which makes the APIs great, intuitive and easy to understand and use and with the APIs getting bigger and bigger (which is great), it is this consistency that allows us developers to quickly and easily grasp new features and changes to the APIs.

PS:
This is – although it might sound different – not meant in an offensive way (quite the opposite: I also want to thank you for enhancing the docs as much as you are). I merely think that it is important to make my point of view (of a developer using the docs) clear here and I can’t deny that having to poke around to hopefully find out if there is any reason for inconsistencies and even new, undocumented types (and if so, what it is), is simply an annoyance when trying to update an open-source project which depends on the docs in my free-time. You know (since I think I’ve already stated so often enough :wink: ) that I absolutely love the APIs, docs and everything around extensibility of XD, so please see this as what it’s meant to be: Constructive criticism to keep those things on the right track and a question about those recent changes.

BTW: I’ve already pointed out another inconsistency about the XD 19 APIs via GitHub. Since, however, I don’t really trust the GitHub notification system and especially no nothing about how it handles those “in-commit inline comments”, here it is: https://github.com/AdobeXD/plugin-docs/commit/8c45b2443a466a46a0ea7875c2439130463e3927#r33544248 :wink:

1 Like

we will take a look at this shortly. Thank you!

1 Like

@pklaschka this is a great feedback and we greatly appreciate it. Our team is still growing and modifications to the docs repository is a team effort (we do not have a dedicated technical writer yet). Until we get to a more stable point, we will try our best to address feedback like this as soon as possible. Again, thanks for the feedback. Please check back the docs and let me know if the issues mentioned by you are addressed now.

1 Like

Perfect, thank you very much. I’ve created a PR fixing a few things to keep the docs of the different modules aligned with each other, but I was able to understand everything to update the typings, so yep, they are pretty much addressed now (and with my PR, they should be fixed 100%) :wink:

The thing I mentioned in the comment (see https://github.com/AdobeXD/plugin-docs/commit/8c45b2443a466a46a0ea7875c2439130463e3927#r33544248) still isn’t “fixed”, but at least for me, that doesn’t have too much priority since it doesn’t “go against” the way the docs work in other places (it just could be some wrong information, but it thankfully isn’t a big deal and developers should be able to understand it already).

Review of my PR would be very much appreciated,
Thank you very much (also in advance) :+1:

@pklaschka I pushed some more updates today with further fixes & clarifications for the XD 19 docs. Just wanted to let you know since you may want to update the typings repo in response.

2 Likes