Skip to content
This repository has been archived by the owner on Oct 6, 2020. It is now read-only.

chore: convert components to ts #150

Merged
merged 14 commits into from
Sep 10, 2020
Merged

Conversation

alextranwork
Copy link
Contributor

@alextranwork alextranwork commented Aug 17, 2020

📃 Summary

Refactor code to provide typings for the Webapp and EMR

🔍 Changeset

  • Everything should behave the same except for autofucus for inputs. Its been changed to autoFocus

🏷 Asana Task

https://app.asana.com/0/0/1186084579231283/f

↩️ Depends On

📸 Screenshots

🧪 QA

  • Need to regression test Webapp and EMR

📈 Risk Analysis

  • Does this affect patients?
  • Does this affect clinical?
  • Does this mutate data?
  • Does it touch PHI?
  • Does it touch payments?
  • Does it update Node packages?

@alextranwork alextranwork changed the title chore/convert components to ts (WIP) chore: convert components to ts (WIP) Aug 17, 2020
@alextranwork
Copy link
Contributor Author

alextranwork commented Aug 18, 2020

@rkrishn7 I reverted your merge because there were too many TS errors. Can you fix the TS errors and try merging again? We can try merging smaller pieces if that help. Also, you can run yarn types to check for errors.

@rkrishn7
Copy link

rkrishn7 commented Aug 18, 2020

@rkrishn7 I reverted your merge because there were too many TS errors. Can you fix the TS errors and try merging again? We can try merging smaller pieces if that help. Also, you can run yarn types to check for errors.

my bad, forgot to cleanup some of the tests/stories. There are a few remaining errors that are coming from Flex and Input. The ones from Flex should be resolved with your changes. Did you convert Input? If so, wanna take a look at that one.

There are a couple errors from src/Card/Card.tsx. Specifically:

& + ${Card.Body} {

Not sure why we use this.

@alextranwork
Copy link
Contributor Author

@rkrishn7 lets create PRs to merge onto this branch. I would like to keep it error free to make it easier. Can you revert your last change since it caused errors again.

@rkrishn7 rkrishn7 force-pushed the chore/convert-components-to-ts branch from bd7444e to 5d0b4cc Compare August 18, 2020 02:12
@alextranwork alextranwork force-pushed the chore/convert-components-to-ts branch from 50e739a to 5d0b4cc Compare August 18, 2020 17:14
@alextranwork alextranwork changed the title chore: convert components to ts (WIP) chore: convert components to ts Aug 26, 2020
@alextranwork alextranwork force-pushed the chore/convert-components-to-ts branch from d54eb8f to 7008e39 Compare August 26, 2020 16:41
@alextranwork alextranwork marked this pull request as ready for review August 26, 2020 16:52
@alextranwork alextranwork requested review from a team August 26, 2020 16:55
@alextranwork alextranwork force-pushed the chore/convert-components-to-ts branch from 0646590 to e33b3a9 Compare August 26, 2020 16:56
import { getComponentVariant, createComponent } from '../utils';

const StyledAlert = createComponent({
export interface AlertProps extends SpaceProps {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking through a couple related PRs, I'm seeing discrepancies around defining props. Here it is an interface, elsewhere I've seen type.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm, I normally use interface to define objects. Is there a reason why we would use type over interfaces for objects?

@alextranwork alextranwork changed the base branch from main to master August 31, 2020 21:41
@alextranwork alextranwork changed the base branch from master to main August 31, 2020 21:42
Copy link

@choochootrain choochootrain left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🚀

@alextranwork alextranwork merged commit 96849ec into main Sep 10, 2020
@delete-merged-branch delete-merged-branch bot deleted the chore/convert-components-to-ts branch September 10, 2020 18:36
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants