-
Notifications
You must be signed in to change notification settings - Fork 1k
Closed
Labels
area:generatorCategory: SharePoint Framework Yeoman generatorCategory: SharePoint Framework Yeoman generatorarea:spfxCategory: SharePoint Framework (not extensions related)Category: SharePoint Framework (not extensions related)status:trackedCurrently tracked with Microsoft’s internal issue tracking system. DO NOT ADD/REMOVE (MSFT managed)Currently tracked with Microsoft’s internal issue tracking system. DO NOT ADD/REMOVE (MSFT managed)type:bug-confirmedConfirmed bug, not working as designed / expected.Confirmed bug, not working as designed / expected.
Description
Category
- Question
- Typo
- Bug
- Additional article idea
Expected or Desired Behavior
Running pnpm install
should get all dependencies so when building the project, it builds with no errors.
Observed Behavior
When you run pnpm install
, you don't get the tslint-microsoft-contrib package. To get it, you must run pnpm install --shamefully-flatten
. This causes a linting error when building:
> gulp build
...
[12:18:50] Error - [tslint] Failed to load /../tslint.json: Could not find custom rule directory: tslint-microsoft-contrib
Ref: https://pnpm.js.org/docs/en/faq.html#pnpm-does-not-work-with-your-project-here
Steps to Reproduce
-
create a new project with the SPFx Yeoman generator:
yo @microsoft/genereator --skip-install
-
run
pnpm install
-
run
gulp build
-
observe linting error listed above
-
use solution 2 from the PNPM FAQ: run
pnpm install --shamefully-flatten
add
--force
to rebuild the node_modules folder without having to delete it -
run
gulp build
-
observe no tslinting errors
Confirmed in SPFx v1.7.0
Metadata
Metadata
Assignees
Labels
area:generatorCategory: SharePoint Framework Yeoman generatorCategory: SharePoint Framework Yeoman generatorarea:spfxCategory: SharePoint Framework (not extensions related)Category: SharePoint Framework (not extensions related)status:trackedCurrently tracked with Microsoft’s internal issue tracking system. DO NOT ADD/REMOVE (MSFT managed)Currently tracked with Microsoft’s internal issue tracking system. DO NOT ADD/REMOVE (MSFT managed)type:bug-confirmedConfirmed bug, not working as designed / expected.Confirmed bug, not working as designed / expected.