You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 20, 2020. It is now read-only.
There is\\"defaultValue\\": { value: 123 } without without double quotes around value key in your test snapshots. Do you know why and is there a way to add " around value key?
I ran to strange bug because of this and that can be fixable here probably.
Let's say I have component Note which has docgenInfo like this.
Then I passing this Note.__docgenInfo in Note.mdx file to component which generate table from it. There it goes wrong because I will get "defaultValue": null instead of "defaultValue": { value: "info" }.
If I do this Note.__docgenInfo = JSON.parse(JSON.stringify(Note.__docgenInfo)); before passing to MDX, I will get "defaultValue": { "value": "info" } which is what I want.
I know there must be some problem with MDX parser discarding that { value: "info" }, but if I can get valid JSON object in __docgenInfo from this loader, that is probably better.
What do you think? I tried to hack the code around to get there that quotes, but without success.
Thank you for your time.
The text was updated successfully, but these errors were encountered:
There is
\\"defaultValue\\": { value: 123 }
without without double quotes around value key in your test snapshots. Do you know why and is there a way to add"
around value key?I ran to strange bug because of this and that can be fixable here probably.
Let's say I have component
Note
which has docgenInfo like this.Then I passing this
Note.__docgenInfo
in Note.mdx file to component which generate table from it. There it goes wrong because I will get"defaultValue": null
instead of"defaultValue": { value: "info" }
.If I do this
Note.__docgenInfo = JSON.parse(JSON.stringify(Note.__docgenInfo));
before passing to MDX, I will get"defaultValue": { "value": "info" }
which is what I want.I know there must be some problem with MDX parser discarding that
{ value: "info" }
, but if I can get valid JSON object in__docgenInfo
from this loader, that is probably better.What do you think? I tried to hack the code around to get there that quotes, but without success.
Thank you for your time.
The text was updated successfully, but these errors were encountered: