Skip to content

refactor(many): use utils import - #27160

Merged
thetaPC merged 10 commits into
feature-7.1from
FW-2845
Apr 12, 2023
Merged

thetaPC merged 10 commits into
feature-7.1from
FW-2845

Conversation

@thetaPC

@thetaPC thetaPC commented Apr 10, 2023 •

Copy link
Copy Markdown
Contributor

What is the current behavior?

Does not use the alias for utils import.

Issue URL: N/A

What is the new behavior?

  • Uses the alias, @utils/*, for the imports

Does this introduce a breaking change?

  • Yes
  • No

Other information

N/A

@bolt-new-by-stackblitz

Copy link
Copy Markdown

Review PR in StackBlitz Codeflow Run & review this pull request in StackBlitz Codeflow.

@github-actions github-actions Bot added the package: core @ionic/core package label Apr 10, 2023
@thetaPC thetaPC changed the title refactor(checkbox, toggle): use utils import refactor(many): use utils import Apr 10, 2023
@thetaPC
thetaPC marked this pull request as ready for review April 10, 2023 21:20

@liamdebeasi liamdebeasi left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Can we create a dev build and test this in a Stencil project? I'm fairly certain the fix for the bug that prevented us from doing this originally already shipped in Stencil, but we've been bitten by this more than once so would like to do an extra check before we merge.

edit: Would be good to try it with a Stencil unit test in that same project too.

@thetaPC

thetaPC commented Apr 11, 2023

Copy link
Copy Markdown
Contributor Author

Can we create a dev build and test this in a Stencil project? I'm fairly certain the fix for the bug that prevented us from doing this originally already shipped in Stencil, but we've been bitten by this more than once so would like to do an extra check before we merge.

edit: Would be good to try it with a Stencil unit test in that same project too.

@liamdebeasi it seems that the issue still persists. I used Stencil's ionic-pwa starter project and used the dev build (@ionic/[email protected]). The project loaded with no issues. The home screen has no visual issues either. However, the console does have errors regarding unknown paths. I suspect that this would lead to functional issues.
Screenshot 2023-04-11 at 10 48 58 AM

On top of that, npm run test fails due to the paths as well even when clearing cache (npx jest --clearCache):
Screenshot 2023-04-11 at 10 52 35 AM

Based on the ticket, I assume that the issue lies with Stencil. Should I close this PR and make an issue over at Stencil?

@liamdebeasi

Copy link
Copy Markdown
Contributor

A few questions:

  1. What is the output when running npm ls @ionic/core?
  2. What is the output when running npm ls @stencil/core?

@thetaPC

thetaPC commented Apr 11, 2023

Copy link
Copy Markdown
Contributor Author

2. npm ls @stencil/core

Here's a screenshot. Let me know if you prefer a text version.
Screenshot 2023-04-11 at 11 05 01 AM

@liamdebeasi

Copy link
Copy Markdown
Contributor

Are you able to isolate the files where the warnings are coming from?

@thetaPC

thetaPC commented Apr 11, 2023

Copy link
Copy Markdown
Contributor Author

Are you able to isolate the files where the warnings are coming from?

I was able to find the file that was causing the issues. I've reverted the paths. No console errors were found when installing the latest dev build (@ionic/[email protected]). Also npm run test runs without issues now.

The issues were coming from:

  1. awaits: await example, then example
  2. types example
  3. constants example

@averyrousseau

Copy link
Copy Markdown
Contributor

Since this is a pretty sweeping change, it may be good to target this to a minor release instead, in case of surprise hidden consequences. We've had a few times where the PR shouldn't have any functional changes, but some edge case was missed that caused regressions, just due to the difficulty of testing this many file updates. Shipping the update in a minor release makes it less likely that devs will be caught off-guard by any regressions, since patch releases are supposed to be pretty safe.

If that's agreeable, we would just need to create a feature-7.1 branch off of main (it doesn't look like it exists yet) and use that as the base branch for this PR instead of main.

@thetaPC

thetaPC commented Apr 12, 2023

Copy link
Copy Markdown
Contributor Author

Since this is a pretty sweeping change, it may be good to target this to a minor release instead, in case of surprise hidden consequences. We've had a few times where the PR shouldn't have any functional changes, but some edge case was missed that caused regressions, just due to the difficulty of testing this many file updates. Shipping the update in a minor release makes it less likely that devs will be caught off-guard by any regressions, since patch releases are supposed to be pretty safe.

If that's agreeable, we would just need to create a feature-7.1 branch off of main (it doesn't look like it exists yet) and use that as the base branch for this PR instead of main.

I'll go ahead and do that, thanks!

@thetaPC
thetaPC changed the base branch from main to feature-7.1 April 12, 2023 20:23
@thetaPC
thetaPC merged commit 0a0345a into feature-7.1 Apr 12, 2023
@thetaPC
thetaPC deleted the FW-2845 branch April 12, 2023 20:25
@thetaPC

thetaPC commented Apr 12, 2023

Copy link
Copy Markdown
Contributor Author

Merged into feature-7.1 branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

package: core @ionic/core package

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants