I ran into a small issue that had quite some impact on our application. To give some context, we use the attributes to name our tokens instead of the token path.
|
transform: token => mapDescriptionToComment(token), |
In the above link, the ts/descriptionToComment is shown and that transformer has a type attribute. However, the transformer itself returns the entire token object instead of only the attributes. This causes the token.attributes to now be the entire token object.
I have done a quick fix on my side by using the name type which is not ideal either but it at least cleans up the attributes.
I ran into a small issue that had quite some impact on our application. To give some context, we use the
attributesto name our tokens instead of the token path.sd-transforms/src/register.ts
Line 54 in 5066620
In the above link, the
ts/descriptionToCommentis shown and that transformer has a typeattribute. However, the transformer itself returns the entire token object instead of only the attributes. This causes thetoken.attributesto now be the entiretokenobject.I have done a quick fix on my side by using the
nametype which is not ideal either but it at least cleans up theattributes.