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

feat: SPFx add web part handling version #10514

Merged
merged 3 commits into from
Dec 15, 2023
Merged

feat: SPFx add web part handling version #10514

merged 3 commits into from
Dec 15, 2023

Conversation

yuqizhou77
Copy link
Contributor

@yuqizhou77 yuqizhou77 commented Dec 12, 2023

Feature 26007373: SPFx add web part by defaut using latest version which bring version mismatch to the original project.

When adding web part, we compare solution version, version of generator installed globally by the user and the version of generator installed locally by TTK, and try to select the package which is in the same version with solution version to continue. If we cannot find, then we will confirm with users to install/upgrade/continue with inconsistent version.

  • Confirm with user if need to install local dependencies
    image

  • Confirm with user if need to upgrade local dependencies
    image

  • Confirm with user to continue
    image

TODO:

  • help doc update

Copy link

codecov bot commented Dec 13, 2023

Codecov Report

Merging #10514 (1f86192) into dev (e92fb78) will increase coverage by 0.17%.
Report is 17 commits behind head on dev.
The diff coverage is 93.87%.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##              dev   #10514      +/-   ##
==========================================
+ Coverage   86.60%   86.78%   +0.17%     
==========================================
  Files         448      450       +2     
  Lines       26235    26421     +186     
  Branches     5235     5280      +45     
==========================================
+ Hits        22722    22930     +208     
+ Misses       1803     1771      -32     
- Partials     1710     1720      +10     
Files Coverage Δ
packages/cli/src/commands/models/addSPFxWebpart.ts 100.00% <100.00%> (ø)
...ages/fx-core/src/component/generator/spfx/error.ts 94.11% <100.00%> (+1.26%) ⬆️
...re/src/component/generator/spfx/utils/constants.ts 100.00% <100.00%> (ø)
.../component/generator/spfx/utils/telemetryEvents.ts 100.00% <100.00%> (ø)
...x-core/src/component/generator/spfx/utils/utils.ts 50.00% <100.00%> (ø)
.../component/generator/spfx/depsChecker/yoChecker.ts 78.88% <95.00%> (+0.06%) ⬆️
...ent/generator/spfx/depsChecker/generatorChecker.ts 78.57% <91.30%> (+2.93%) ⬆️
...core/src/component/generator/spfx/spfxGenerator.ts 85.79% <93.10%> (+3.31%) ⬆️

... and 22 files with indirect coverage changes

refactor: telemetry

refactor: more

refactor: minor

refactor: cli

test: ut

test: ut

test: ut1

test: ut2

test: ut3

test: ut

test: ut

test: ut

refactor: minor
nliu-ms
nliu-ms previously approved these changes Dec 14, 2023
packages/fx-core/resource/package.nls.json Outdated Show resolved Hide resolved
packages/fx-core/resource/package.nls.json Outdated Show resolved Hide resolved
packages/fx-core/resource/package.nls.json Outdated Show resolved Hide resolved
packages/fx-core/resource/package.nls.json Outdated Show resolved Hide resolved
packages/fx-core/resource/package.nls.json Outdated Show resolved Hide resolved
packages/fx-core/resource/package.nls.json Outdated Show resolved Hide resolved
packages/fx-core/resource/package.nls.json Outdated Show resolved Hide resolved
@yuqizhou77 yuqizhou77 merged commit 3a2a715 into dev Dec 15, 2023
20 checks passed
@yuqizhou77 yuqizhou77 deleted the yuqzho/add-webpart branch December 15, 2023 02:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants