Get 2024 Templates Mega Bundle!14 Bootstrap, Vue & React Templates + 3 Vector Sets
Get for 99$

v8.1.8 Demo 1 for Blazor Doesn't Compile


I downloaded the latest version of the Blazor demo (Demo 1) and followed the instructions found here:

https://preview.keenthemes.com/blazor/metronic/docs/getting-started

The yarn install produces this:


D:\Projects\Scholarky\Source-Previous\New\blazor_demo1\Starterkit\_keenthemes\tools>yarn install
➤ YN0000: ┌ Resolution step
➤ YN0002: │ @prettier-x/formatter-2021-01@npm:0.0.1-rc01 [b0008] doesn"t provide remark-parse (pc96b9), requested by remark-math
➤ YN0002: │ bootstrap-maxlength@npm:1.10.1 doesn"t provide popper.js (p0823b), requested by bootstrap
➤ YN0002: │ datatables.net-plugins@npm:1.13.4 doesn"t provide prettier (p05515), requested by prettier-plugin-x
➤ YN0002: │ keenthemes@workspace:. doesn"t provide @egjs/hammerjs (p26ff8), requested by vis-timeline
➤ YN0002: │ keenthemes@workspace:. doesn"t provide component-emitter (p27f09), requested by vis-timeline
➤ YN0002: │ keenthemes@workspace:. doesn"t provide keycharm (pdb290), requested by vis-timeline
➤ YN0002: │ keenthemes@workspace:. doesn"t provide postcss (p6730e), requested by postcss-loader
➤ YN0002: │ keenthemes@workspace:. doesn"t provide prop-types (p425cc), requested by @yaireo/tagify
➤ YN0002: │ keenthemes@workspace:. doesn"t provide propagating-hammerjs (pd5b8f), requested by vis-timeline
➤ YN0002: │ keenthemes@workspace:. doesn"t provide uuid (pcd607), requested by vis-timeline
➤ YN0002: │ keenthemes@workspace:. doesn"t provide vis-data (p6f481), requested by vis-timeline
➤ YN0002: │ keenthemes@workspace:. doesn"t provide vis-util (pe63ac), requested by vis-timeline
➤ YN0002: │ keenthemes@workspace:. doesn"t provide xss (pb7573), requested by vis-timeline
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#130; Some peer dependencies are incorrectly met; run yarn explain peer-requirements <hash> for details, where <hash> is the six-letter p-prefixed code
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#148; Completed
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#140; Fetch step
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#148; Completed in 0s 341ms
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#140; Link step
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#130; ESM support for PnP uses the experimental loader API and is therefore experimental
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#148; Completed
&acirc;&#158;&curren; YN0000: Done with warnings in 0s 727ms


Then, I try to run the gulp command and I get this:


D:\Projects\Scholarky\Source-Previous\New\blazor_demo1\Starterkit\_keenthemes\tools>gulp
[22:25:32] Local modules not found in D:\Projects\Scholarky\Source-Previous\New\blazor_demo1\Starterkit\_keenthemes\tools
[22:25:32] Try running: yarn install


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(

Replies (16)


Hi Keith,

Thank you for reaching out to us.

Unfortunately, after checking this further we were not able to reproduce this issue.

Could you please specify your node and yarn versions?

Try to clear npm cache and reinstall npm dependencies.


  1. Delete node_modules and yarn.lock/pacakge-lock.json.

  2. Run command to clear npm cache npm cache clean --force.

  3. Then install dependencies again with npm install or yarn install.



Regards,
Lauris Stepanovs,
Keenthemes Support Team

Node: v18.16.0
Yarn: 3.6.0

I couldn't find a node_modules folder nor yarn.lock folder, but I ran the npm cache clean and then npm install (instead of using yarn) and then removed the module line from package.json and ran npm run build:


D:\Projects\Scholarky\Source-Previous\New\Starterkit\_keenthemes\tools>npm run build

> keenthemes@1.0.0 build
> webpack

[webpack-cli] Failed to load "D:\Projects\Scholarky\Source-Previous\New\Starterkit\_keenthemes\tools\webpack.config.js" config
[webpack-cli] Error: Cannot find module "webpack-log"
Require stack:
- D:\Projects\Scholarky\Source-Previous\New\Starterkit\_keenthemes\tools\node_modules\webpack-exclude-assets-plugin\lib\index.js
- D:\Projects\Scholarky\Source-Previous\New\Starterkit\_keenthemes\tools\node_modules\webpack-exclude-assets-plugin\index.js
- D:\Projects\Scholarky\Source-Previous\New\Starterkit\_keenthemes\tools\webpack.config.js
- D:\Projects\Scholarky\Source-Previous\New\Starterkit\_keenthemes\tools\node_modules\webpack-cli\lib\webpack-cli.js
- D:\Projects\Scholarky\Source-Previous\New\Starterkit\_keenthemes\tools\node_modules\webpack-cli\lib\bootstrap.js
- D:\Projects\Scholarky\Source-Previous\New\Starterkit\_keenthemes\tools\node_modules\webpack-cli\bin\cli.js
- D:\Projects\Scholarky\Source-Previous\New\Starterkit\_keenthemes\tools\node_modules\webpack\bin\webpack.js
at Module._resolveFilename (node:internal/modules/cjs/loader:1075:15)
at Module._load (node:internal/modules/cjs/loader:920:27)
at Module.require (node:internal/modules/cjs/loader:1141:19)
at require (node:internal/modules/cjs/helpers:110:18)
at Object.<anonymous> (D:\Projects\Scholarky\Source-Previous\New\Starterkit\_keenthemes\tools\node_modules\webpack-exclude-assets-plugin\lib\index.js:1:16)
at Module._compile (node:internal/modules/cjs/loader:1254:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1308:10)
at Module.load (node:internal/modules/cjs/loader:1117:32)
at Module._load (node:internal/modules/cjs/loader:958:12)
at Module.require (node:internal/modules/cjs/loader:1141:19) {
code: "MODULE_NOT_FOUND",
requireStack: [
"D:\\Projects\\Scholarky\\Source-Previous\\New\\Starterkit\\_keenthemes\\tools\\node_modules\\webpack-exclude-assets-plugin\\lib\\index.js",
"D:\\Projects\\Scholarky\\Source-Previous\\New\\Starterkit\\_keenthemes\\tools\\node_modules\\webpack-exclude-assets-plugin\\index.js",
"D:\\Projects\\Scholarky\\Source-Previous\\New\\Starterkit\\_keenthemes\\tools\\webpack.config.js",
"D:\\Projects\\Scholarky\\Source-Previous\\New\\Starterkit\\_keenthemes\\tools\\node_modules\\webpack-cli\\lib\\webpack-cli.js",
"D:\\Projects\\Scholarky\\Source-Previous\\New\\Starterkit\\_keenthemes\\tools\\node_modules\\webpack-cli\\lib\\bootstrap.js",
"D:\\Projects\\Scholarky\\Source-Previous\\New\\Starterkit\\_keenthemes\\tools\\node_modules\\webpack-cli\\bin\\cli.js",
"D:\\Projects\\Scholarky\\Source-Previous\\New\\Starterkit\\_keenthemes\\tools\\node_modules\\webpack\\bin\\webpack.js"
]
}


Could it be that I need a different version of node or yarn?



I copied another instance of the StarterKit to my C drive instead of my data drive (D) and re-ran the commands and it worked. Maybe there is something hardcoded to look for something on the C drive of a Windows machine?



Hi Keith,

Sorry for the delay in reply.

The build should work with your node and yarn versions.

After checking this it seems like there aren't any hard-coded paths referring to the exact drive.

Just for a test, can you try to build assets in our HTML version on your D drive?

Regards,
Lauris Stepanovs,
Keenthemes Support Team



I tried my C and D drives and I get different errors now. I tried your recommended resolution of clearing the npm cache and deleting those files, but I get this error now:


C:\temp\metronic\blazor_demo1\Starterkit\_keenthemes\tools>npm run build

> keenthemes@1.0.0 build
> webpack

Source: C:/temp/metronic/blazor_demo1/themes/null/html/src
Output: C:/temp/metronic/blazor_demo1/themes/null/html/dist/assets
[webpack-cli] Invalid configuration object. Webpack has been initialized using a configuration object that does not match the API schema.
- configuration[0].entry['js/widgets.bundle'] should be a non-empty array.
-> All modules are loaded upon startup. The last one is exported.



Hi Keith,

Thank you for bringing this issue to our attention. We have investigated it, and it appears that the problem occurs specifically on Windows. As a temporary workaround, we suggest the following modification to the webpack.config.js file:

Find this line:

entries["js/widgets.bundle"] = ...


Replace it with the following code block:

entries["js/widgets.bundle"] = (glob.sync(path.relative("./", srcPath).replaceAll(/\\/g, "/") + "/js/widgets/**/!(_)*.js") || []).map(file => {
return file.replaceAll(/\\/g, "/");
});


You can also find the full webpack.config.js file with the modification in this gist: https://gist.github.com/KeenthemesHub/2189b96490016bc32f88b3091e446906#file-webpack-config-js-L114-L116

Please change the highlighted lines only.

After making this change, please run the build process again to see if the issue is resolved on your Windows environment.

If you encounter any other difficulties or need further assistance, do not hesitate to reach out.

Regards,
Lauris Stepanovs,
Keenthemes Support Team



I made the change that you suggested and then tried yarn and npm and they both fail. Here is the output from the yarn install method:


C:\temp\metronic\blazor_demo1\Starterkit\_keenthemes\tools>yarn install
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#140; Resolution step
&acirc;&#158;&curren; YN0061: &acirc;&#148;&#130; chokidar@npm:2.1.8 is deprecated: Chokidar 2 does not receive security updates since 2019. Upgrade to chokidar 3 with 15x fewer dependencies
&acirc;&#158;&curren; YN0061: &acirc;&#148;&#130; source-map-resolve@npm:0.6.0 is deprecated: See https://github.com/lydell/source-map-resolve#deprecated
&acirc;&#158;&curren; YN0061: &acirc;&#148;&#130; core-js@npm:2.6.12 is deprecated: core-js@<3.23.3 is no longer maintained and not recommended for usage due to the number of issues. Because of the V8 engine whims, feature detection in old core-js versions could cause a slowdown up to 100x even if nothing is polyfilled. Some versions have web compatibility issues. Please, upgrade your dependencies to the actual version of core-js.
&acirc;&#158;&curren; YN0032: &acirc;&#148;&#130; fsevents@npm:2.3.2: Implicit dependencies on node-gyp are discouraged
&acirc;&#158;&curren; YN0061: &acirc;&#148;&#130; fsevents@npm:1.2.13 is deprecated: The v1 package contains DANGEROUS / INSECURE binaries. Upgrade to safe fsevents v2
&acirc;&#158;&curren; YN0061: &acirc;&#148;&#130; source-map-resolve@npm:0.5.3 is deprecated: See https://github.com/lydell/source-map-resolve#deprecated
&acirc;&#158;&curren; YN0032: &acirc;&#148;&#130; nan@npm:2.17.0: Implicit dependencies on node-gyp are discouraged
&acirc;&#158;&curren; YN0061: &acirc;&#148;&#130; resolve-url@npm:0.2.1 is deprecated: https://github.com/lydell/resolve-url#deprecated
&acirc;&#158;&curren; YN0061: &acirc;&#148;&#130; source-map-url@npm:0.4.1 is deprecated: See https://github.com/lydell/source-map-url#deprecated
&acirc;&#158;&curren; YN0061: &acirc;&#148;&#130; urix@npm:0.1.0 is deprecated: Please see https://github.com/lydell/urix#deprecated
&acirc;&#158;&curren; YN0061: &acirc;&#148;&#130; sourcemap-codec@npm:1.4.8 is deprecated: Please use @jridgewell/sourcemap-codec instead
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; bootstrap-maxlength@npm:1.10.1 doesn"t provide popper.js (p0823b), requested by bootstrap
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; keenthemes@workspace:. doesn"t provide @egjs/hammerjs (p26ff8), requested by vis-timeline
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; keenthemes@workspace:. doesn"t provide component-emitter (p27f09), requested by vis-timeline
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; keenthemes@workspace:. doesn"t provide keycharm (pdb290), requested by vis-timeline
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; keenthemes@workspace:. doesn"t provide postcss (pcd48b), requested by postcss-loader
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; keenthemes@workspace:. doesn"t provide prop-types (p425cc), requested by @yaireo/tagify
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; keenthemes@workspace:. doesn"t provide propagating-hammerjs (pd5b8f), requested by vis-timeline
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; keenthemes@workspace:. doesn"t provide uuid (pcd607), requested by vis-timeline
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; keenthemes@workspace:. doesn"t provide vis-data (p6f481), requested by vis-timeline
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; keenthemes@workspace:. doesn"t provide vis-util (pe63ac), requested by vis-timeline
&acirc;&#158;&curren; YN0002: &acirc;&#148;&#130; keenthemes@workspace:. doesn"t provide xss (pb7573), requested by vis-timeline
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#130; Some peer dependencies are incorrectly met; run yarn explain peer-requirements <hash> for details, where <hash> is the six-letter p-prefixed code
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#148; Completed in 5s 360ms
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#140; Fetch step
&acirc;&#158;&curren; YN0013: &acirc;&#148;&#130; yargs-parser@npm:5.0.1 can"t be found in the cache and will be fetched from the remote registry
&acirc;&#158;&curren; YN0013: &acirc;&#148;&#130; yargs@npm:17.7.2 can"t be found in the cache and will be fetched from the remote registry
&acirc;&#158;&curren; YN0013: &acirc;&#148;&#130; yargs@npm:7.1.2 can"t be found in the cache and will be fetched from the remote registry
&acirc;&#158;&curren; YN0013: &acirc;&#148;&#130; yarn-install@npm:1.0.0 can"t be found in the cache and will be fetched from the remote registry
&acirc;&#158;&curren; YN0013: &acirc;&#148;&#130; yocto-queue@npm:0.1.0 can"t be found in the cache and will be fetched from the remote registry
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#148; Completed in 2s 481ms
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#140; Link step
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#130; ESM support for PnP uses the experimental loader API and is therefore experimental
&acirc;&#158;&curren; YN0007: &acirc;&#148;&#130; @fortawesome/fontawesome-free@npm:6.4.2 must be built because it never has been before or the last one failed
&acirc;&#158;&curren; YN0007: &acirc;&#148;&#130; core-js@npm:2.6.12 must be built because it never has been before or the last one failed
&acirc;&#158;&curren; YN0007: &acirc;&#148;&#130; es5-ext@npm:0.10.62 must be built because it never has been before or the last one failed
&acirc;&#158;&curren; YN0007: &acirc;&#148;&#130; vis-timeline@npm:7.7.2 [a754c] must be built because it never has been before or the last one failed
&acirc;&#158;&curren; YN0000: &acirc;&#148;&#148; Completed in 3s 186ms
&acirc;&#158;&curren; YN0000: Done with warnings in 11s 184ms


Then gulp:


C:\temp\metronic\blazor_demo1\Starterkit\_keenthemes\tools>gulp
[08:18:05] Local modules not found in C:\temp\metronic\blazor_demo1\Starterkit\_keenthemes\tools
[08:18:05] Try running: yarn install


And this is extracting a fresh copy, making the config change (line 114) and using npm:

C:\temp\metronic\blazor_demo1\Starterkit\_keenthemes\tools>npm run build

> keenthemes@1.0.0 build
> webpack

Source: C:/temp/metronic/blazor_demo1/themes/null/html/src
Output: C:/temp/metronic/blazor_demo1/themes/null/html/dist/assets
[webpack-cli] Invalid configuration object. Webpack has been initialized using a configuration object that does not match the API schema.
- configuration[0].entry["js/widgets.bundle"] should be a non-empty array.
-> All modules are loaded upon startup. The last one is exported.



Hi,

We tested our theme with LTS Node and Npm versions.

Node: 18.17.0
Npm: 9.6.7

But installation should still work with your node and npm versions.

Are you using the latest Metronic Blazor Starterkit?

Regards,
Lauris Stepanovs,
Keenthemes Support Team



Downloaded the Blazor Starterkit directly from your site, ran yarn install, then gulp and got this:



Node Version: v20.3.0
Npm Version: v9.6.7



Hi,

Could you please try to install Gulp globally?

npm install -g gulp


Regards,
Lauris Stepanovs,
Keenthemes Support Team



Hi,

We tested our theme on various environments but couldn't replicate the same outcome. The same error occurs when we run the gulp command before installing dependencies.

Does the installation command generate a node_modules folder in the _keenthemes/tools directory?

Regards,
Lauris Stepanovs,
Keenthemes Support Team



It does not. So which dependencies do I need to install prior to running the gulp command?



Hi,

Commands yarn install or npm install should install all necessary dependencies and put them into keenthemes/tools/node_modules.

Regards,
Lauris Stepanovs,
Keenthemes Support Team



npm install fixed it. maybe include that in the documentation?



Hi,

This information is already included in our getting started docs.
See https://preview.keenthemes.com/blazor/metronic/docs/getting-started

Regards,
Lauris Stepanovs,
Keenthemes Support Team


Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(
Text formatting options
Submit
Here's a how to add some HTML formatting to your comment:
  • <pre></pre> for JS codes block
  • <pre lang="html"></pre> for HTML code block
  • <pre lang="scss"></pre> for SCSS code block
  • <pre lang="php"></pre> for PHP code block
  • <code></code> for single line of code
  • <strong></strong> to make things bold
  • <em></em> to emphasize
  • <ul><li></li></ul>  to make list
  • <ol><li></li></ol>  to make ordered list
  • <h3></h3> to make headings
  • <a></a> for links
  • <img> to paste in an image
  • <blockquote></blockquote> to quote somebody
  • happy  :)
  • shocked  :|
  • sad  :(