Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: cannot use IonItem with IonRouter on React-Tests #22986

Closed
BerkeAras opened this issue Feb 28, 2021 · 5 comments
Closed

bug: cannot use IonItem with IonRouter on React-Tests #22986

BerkeAras opened this issue Feb 28, 2021 · 5 comments
Labels

Comments

@BerkeAras
Copy link

Bug Report

Ionic version:

[ ] 4.x
[x] 5.x

Current behavior:
Cannot use IonItem with IonRouter on React Tests at "/packages/react/test/test-app/". Getting error: Property 'routerAnimation' is missing in type '{ children: Element[]; button: true; }' but required in type 'Pick<IonItem, "color" | "button" | "disabled" | "lines" | "mode" | "href" | "routerAnimation" | "rel" | "target" | "download" | "type" | "detail" | "detailIcon">'. TS2741

Expected behavior:
IonRouter should get the property routerAnimation.

Steps to reproduce:
See steps: #22342 (comment)

Related code:
https://github.com/ionic-team/ionic-framework/tree/master/packages/react/test/test-app

Other information:
Issue #22342 cannot be fixed without testing and fixing this issue..

Ionic info:
Cannot give ionic info because of working in the Source Code of Ionic Framework.

@ionitron-bot ionitron-bot bot added the triage label Feb 28, 2021
@liamdebeasi
Copy link
Contributor

Sorry, the react/test/test-app is old. Can you give this a try with react-router/test/test-app?

@liamdebeasi liamdebeasi added the needs: reply the issue needs a response from the user label Mar 1, 2021
@ionitron-bot ionitron-bot bot removed the triage label Mar 1, 2021
@BerkeAras
Copy link
Author

@liamdebeasi Unfortunately I just got an error and I still can't fix it :(

  1. Error: Cannot find module 'react-dev-utils/getPublicUrlOrPath'
  2. npm ERR! enoent ENOENT: no such file or directory, stat '/Users/berkearas/Desktop/ionic-framework/packages/react/ionic-react-5.5.0.tgz'

@ionitron-bot ionitron-bot bot added triage and removed needs: reply the issue needs a response from the user labels Mar 2, 2021
@liamdebeasi
Copy link
Contributor

For 1) make sure you have run npm install first.

For 2) follow these steps:

  1. In the test-app directory, change ionic-react-5.5.0 in both package.json and build.sh to ionic-react-5.5.5. This assume you have the latest master.
  2. Run ./build.sh. This assumes you have installed dependencies in the react directory first.

The steps here are not the most intuitive, so I can document these somewhere in the readme.

@BerkeAras
Copy link
Author

BerkeAras commented Mar 2, 2021

@liamdebeasi It works now. It has to be like this:

  1. Update the correct version in /packages/react-router/test-app/package.json and /packages/react-router/test-app/build.sh
  2. sh build.sh in /packages/react-router/test-app/
  3. npm install in /packages/react-router/test-app/
  4. npm start in /packages/react-router/test-app/

Unfortunately on my MacBook npm install did not work, but npm install --force.
Thanks for helping, I can now focus on #22342

@ionitron-bot
Copy link

ionitron-bot bot commented Apr 1, 2021

Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.

@ionitron-bot ionitron-bot bot locked and limited conversation to collaborators Apr 1, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants