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
When importing import t from "flow-runtime"; it looks like all the functions under t are for describing new types. The documentation also talks about describing types and I need to get the description in runtime.
Which package versions are you using?
"flow-runtime": "^0.17.0"
What is the expected behaviour?
I'm searching for a way to examine existing classes.
I've added flow-runtime to my existing project which already uses flow.
I have type annotations on every class property in my project.
If you're trying to marshal JSON objects into classes, it may be an uphill battle... for better or worse I think using plain JS objects and making functions that operate on them instead of class methods would probably be easier in the long run. Even Babel outputs AST nodes as plain JS objects instead of class instances AFAIK. (EDIT: Okay, it uses a Node prototype, but it doesn't seem to have any methods, or class hierarchy). This is totally different from how things are done in Java for example, and it took me awhile to get used to it.
This is a:
Which concerns:
What is the current behaviour?
When importing
import t from "flow-runtime";
it looks like all the functions undert
are for describing new types. The documentation also talks about describing types and I need to get the description in runtime.Which package versions are you using?
"flow-runtime": "^0.17.0"
What is the expected behaviour?
I'm searching for a way to examine existing classes.
I've added flow-runtime to my existing project which already uses flow.
I have type annotations on every class property in my project.
For example:
I've added the following to the start of my babel plugins list:
["flow-runtime", {"assert": false, "annotate": true}]
.All I want, is to get an array of properties names so I can validate a JSON parsed object against it.
Can I achieve this behavior with this library?
The text was updated successfully, but these errors were encountered: