Skip to content

react-personal-greeting - Invalid glob argument  #5112

@Jeyeline

Description

@Jeyeline

Disclaimer

Yes

Sample

react-personal-greeting

Contributor(s)

@zachroberts8668

What happened?

Receiving the below error

Error - [copy-assets] Error: Invalid glob argument:
Error - 'copy-assets' sub task errored after 32 ms
Invalid glob argument:
'bundle' errored after 13 s
About to exit with code: 1
Process terminated before summary

while executing gulp bundle --ship

Steps to reproduce

  1. clone code in url https://github.com/pnp/sp-dev-fx-webparts/blob/main/samples/react-personal-greeting/README.md
  2. execute npm install
  3. execute gulp build
  4. execute gulp bundle --ship
    Error is encountered

Expected behavior

The build should be successful and the package has to be published upon executing gulp package-solution --ship

Target SharePoint environment

SharePoint Online

Developer environment

Windows

Browsers

  • Internet Explorer
  • Microsoft Edge
  • Google Chrome
  • FireFox
  • Safari
  • mobile (iOS/iPadOS)
  • mobile (Android)
  • not applicable
  • other (enter in the "Additional environment details" area below)

What version of Node.js is currently installed on your workstation?

10.24.1

What version of Node.js is required by the sample?

=8.9.4 <9.0.0 || >=10.13.0 <11.0

Paste the results of SPFx doctor

npm\node_modules@pnp\cli-microsoft365\dist\index.js:2
import { cli } from './cli/cli.js';
^

SyntaxError: Unexpected token {
at Module._compile (internal/modules/cjs/loader.js:723:23)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Function.Module.runMain (internal/modules/cjs/loader.js:831:12)
at startup (internal/bootstrap/node.js:283:19)
at bootstrapNodeJSCore (internal/bootstrap/node.js:623:3)

Additional environment details

No response

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions