I am trying out html-webpack-plugin for Webpack by following their documentation. But it seems to be not generating the required html file. I have created a small bare-bone project to reproduce the error. github project to highlight the error I would appreciate if someone can point out my error. Use the following script to see the result in the project directory:
npm install
node_modules/.bin/webpack
Related
I have created one npm package,that uses webpack for bundling the source code.i am able to use my package locally with reactjs but when I try to use my package with vuejs it shows me the following errors
Error: No ESLint configuration found in G:\development\Webdevelopment\purple_project\dist.
at CascadingConfigArrayFactory._finalizeConfigArray (G:\development\Webdevelopment\vue-test\node_modules\eslint\lib\cli-engine\cascading-config-array-factory.js:432:19)
I have searched a lot but no answers are satisfying.thanks in advance
I am getting the below error when doing next build in my next.js app, after it's been working fine with just next (or npm run dev).
The error:
$ next build
The module 'react-dom' was not found. Next.js requires that you include it in 'dependencies' of your 'package.json'. To add it, run 'npm install --save react-dom'
Creating an optimized production build ...
> Using external babel configuration
> Location: "../.babelrc"
Failed to compile.
./pages/_app.js
Module not found: Can't resolve 'next/head' in '../pages'
> Build error occurred
Error: > Build failed because of webpack errors
at build (.../AppData/Roaming/npm/node_modules/next/dist/build/index.js:7:847)
I started my project by cloning Material UI's next.js example and just use that as it seems updated:
https://github.com/mui-org/material-ui/tree/master/examples/nextjs
However, thinking I just may of have an outdated or broken build, I re-cloned the next.js example and did next build as well, without modifying any files and I get the same error.
How can I fix this?
I just cloned that next.js example and it worked both with npm run dev, as well as npm run build->npm run start.
Judging by your error, I would check that "react-dom": "latest" is present in your package.json's dependencies. Did you run npm install after cloning the example?
The solution to this problem is to Just rerun these two commands again then your project will successfully Run. I also faced this problem but I got the solution.
npm i
yarn install
I ran into a similar problem when I included my nextjs app in a yarn workspace. I got around the issue by deleting the following directories in my nextjs app:
node_modules
.next
build
After removing them I ran yarn from the repo directory and started the nextjs app back up and it was working again.
When a blank Create React App is created and the MidiConvert library is a dependency, it is fine for developing. As soon as a build is started it gives the following error indicating it tries to minify the source file:
$ react-scripts build
Creating an optimized production build...
Failed to compile.
Failed to minify the code from this file:
./node_modules/midiconvert/src/Util.js:20
Read more here: https://github.com/facebook/create-react-app/blob/master/packages/react-scripts/template/README.md#npm-run-build-fails-to-minify
error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command.
In the package.json from MidiConvert the following entry triggers the build of the source files.
"module": "src/MidiConvert.js",
When removed, the React project builds.
Relevant links:
React project implementing MidiConvert
Travis error build log
Package JSON with erroring line of MidiConvert
I am currently working on integrating a chat system into my web application. This is the project which is given to me to take as a base: https://github.com/smilefam/SendBird-JavaScript/tree/master/web-widget
I have made some changes to the JS and SCSS files. Now how do I build it into the single Javascript file so that I can import it to my application?
I am executing the following command
npm run build
But it throws an error saying,
npm ERR! missing script: build
I am a complete newbie to Node and hence looking for some help.
From what I can see in your package.json I understand that you have not defined a build command under the scripts section.
Adding a build command there should work.
This error appears because you don't have a build script inside of the scripts field in your package.json.
Your scripts should be defined in your package.json.
To read more information about how to make a package.json, click on here
Hope this helps.
I'm just starting out with ember JS and my basic application seemed to be working like a charm, till I decided to add ember-cli-simple-auth through the ember cli. Since I have added this, I'm getting the error in the title and I have no clue how.
I know there is not much detail I have provided, but this is all I can think of. I tried uninstalling the ember-cli-simple-auth library but it doesn't help. Any help here would be really appreciated.
As the error indicate
ENOENT: no such file or directory, bower_components\bootstrap\js\transition.js'
there is no directory called bower_components, that means the dependencies are not installed.
To install dependencies, run
> bower install
command on the terminal from the root directory of the project where bower.json file is located.
This will install all the front-end dependencies in the bower_components folder.