[flow] switch from PropTypes to Props
We would like to switch from using PropTypes to flow props because it gives us a lot more coverage. I switched the Tabs component and learned a lot in the process.
We've done most of them, and just have a few to go!
todolist
- [x] Frames/index.js
- [ ] CommandBar.js
- [ ] TextSearch.js
- [x] ProjectSearch/index.js
- [ ] Editor/index.js
- [ ] App.js
Cool! Lemme try one! I'll take Footer
I'll try one too.
wondering how does it work, is props stripped down later? or converted to PropTypes by a transform? I have no flow experience, so I could have missed something here
@Andarist it's stripped away. It's basically acknowledging that we're going to use flow and static type our code. Want to jump in and claim a file?
Yeah, already cloned and looking at EventListeners and reading dev guides ;)
Would be cool if they could be transformed to PropTypes if u distribute this as module (whatever if umd, cjs or smth else). You might have switched to flow, consumers of this as library might not.
@jasonLaster
can try SearchBar next
Go for it On Fri, May 5, 2017 at 7:34 PM Mateusz Burzyński [email protected] wrote:
@jasonLaster https://github.com/jasonLaster can try SearchBar next
— You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub https://github.com/devtools-html/debugger.html/issues/2804#issuecomment-299598417, or mute the thread https://github.com/notifications/unsubscribe-auth/AAPiYvUyxbAeWOJ7ayVnD3oTWYQwborgks5r27IagaJpZM4NQDrw .
I'd to like to take up "Expressions"
Im also working on HitMarker
Thanks!
On Fri, May 19, 2017 at 11:48 AM Peter Schussheim [email protected] wrote:
@jasonLaster https://github.com/jasonlaster Starting work on shared/Popover
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/devtools-html/debugger.html/issues/2804#issuecomment-302739679, or mute the thread https://github.com/notifications/unsubscribe-auth/AAPiYojxRvd4F0sCjN8Wt69Iggm_sApFks5r7bnLgaJpZM4NQDrw .
Is this an updated list? I think I'll start with shared/Accordion and shared/Autocomplete.
probably not, we try to keep it up to date :)
I'll take Popover
I'll take CommandBar!
@satiewaltz its yours
@jasonLaster
Just thought I should make a note about this: I've been checking out the conversion to flow types issue in this project. Some components listed in that issue use the Context API for the shortcuts component. I've done some research into it - and it seems like a runtime type library is required to convert from contextTypes to flow types: https://github.com/codemix/flow-runtime. I think its something that should be noted in the issue when people make PRs that use that component.
Thanks @satiewaltz, I'd be open to using flow-runtime as well. Thanks for the update. Also, it's okay not to type context :) we use it very sparingly.
Did some checking
Primary Panes / Outline looks done Primary Panes / Sources - cannot find the file, has ist been (re-)moved? Secondary Panes / Breakpoints looks done and seems only be missing the checkmark in this ticket. Secondary Panes / Why Paused looks also done Shared / Button / Close looks also done Shared / ManagedTree looks also done Shared / ObjectInspector -> cannot find the file, has it been (re-)moved? (looks like it has been moved to another module) Secondary Panes / CommandBar has only contextTypes left
Looks line Primary Panes / Sources Tree ist the only file left that has to be transformed.
@amelzer Note: CommandBar's contextTypes can only be switched out if a runtime type library is used like flow-runtime as noted earlier from when I was looking at it. Fortunately, only several components have contextTypes defined in them: it's all places that inherits context from the shortcuts component.
Maybe that component can be marked done unless there's an alternative way to convert it that I've missed?
@satiewaltz Yes, I got that, that's why it is in this done-ish list :)