-
-
Notifications
You must be signed in to change notification settings - Fork 6.3k
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
These relative modules were not found: #439
Comments
I got the same problem like this:
|
@williamstar how did u solve it ? |
@xerosanyam In my case , I use the vscode and run the app by F5 at the dev-server or node dev-server.js because I want to debugg some detail. But you can run npm run dev to solve this problem, if you want to debugger code may be can use the chrome debugger symbol embed into code. |
Was this solved? If so can someone post the solution? |
Can someone please post the solution ? |
I solved it by updating all the npm packages by:
please commit your package.json before performing above operation |
can someone solve this problem? |
The solution I have suggested above doesnt work for you ? |
@xerosanyam Doesnt work ); |
@xerosanyam The second input is invalid |
@Tzrong 你的问题解决了吗 |
你会说英语吗? |
@MrGrimod 你是说我? |
是的,但谷歌翻译器确实可以中国。因此,不要在意。 |
@MrGrimod 哈哈 没事 大家能指出问题所在就好 |
These relative modules were not found: |
@Xuhengfeng 我也一直没找到方法,一直在等 |
This relative module was not found:
|
I got this error when I messed up the case of the filename. When I ran this on a build server running Linux (I use Mac for development) it failed because OS X is case-insensitive and Debian is case-sensitive. |
I'm solved by next commands:
|
i have same problem, but I'm solved by next commands |
This may cause by project inited in an existing vue-cli project, I dig myself into a hole, lol. |
If you haven't messed up with your webpack config, it is most likely that you have an issue with one of the npm packages. Clean/Verify the npm cache and then run the below commands, thats how I solved this.
|
Check the path you are using. |
I'm solved by re-install all modules :)
|
|
I have very similar problem. When I do "npm run serve" or "npm run build" I get this on console:
None of solutions suggested above has no any effect. Here is my main.ts
And here App.vue
Vue ^2.5.13, project created via vue cli ^3.0.0-beta.6 (also tried beta.15), using Typescript cli plugin ^3.0.0-beta.6 |
Hi everyone, |
yeah tried it also |
This work for me, Thanks! |
how did u solve? |
check your resources path if it is not in the same folder then use double dot instead of single dot in my case
|
I run everything in the Docker container, and the working folder was not the one with which I registered the files in tsconfig.json; apparently tsconfig.json inclide, trying to get files NOT relative to the location of the tsconfig.json file, but relative to the current WORKING DIRECTORY through which the script is running. I hope no one forgot to register ts extensions in webpack config? =)) resolve: {
extensions: ['.ts', '.tsx', '.js', '.jsx'],
}, |
It seems that I caused this problem because I changed the paths of my imports when I was running my application with npm run serve. This made my cache upset. I simply stopped the application (Ctrl + c) changed the path back. Ran the application again (npm run serve) and made sure it was back to normal. Stopped the application (ctrl +c), changed my paths and then I ran it again. In conclusion, do not change any paths when the app is running. You must stop it first and run it again. The imports look something like this: <script> import Navbar from '../../components/firstPath/Navbar' </script <script> import Navbar from '../../components/modifiedPath/Navbar' </script |
For anyone still reading and realized their issue was slightly different, make sure the case matches what's in the directory.
My app worked flawlessly until I upgraded my tooling. If my file name was somefile.vue or someFile.vue it failed with a similar error. |
For people still struggling with this you may try specifying the file to serve in package.json. This moved me past this error. I changed: I started running into another error at this point, but this at least resolved the "this relative module was not found" error |
In my case I simply forgot I was trying to reference the old file in a different component! Most likely human error |
in case you are having the `This relative module was not found:
look for import func from '..vue-temp/vue-editor-bridge' in your template and remove it |
Somehow, after mounting public & src folders in read-only mode the error disappears. I suspect this is related to fsevents. |
What worked for me, was somehow described above.
|
In my case the problem was that it was looking for a main.js file in my code but couldn't find it - instead I had an app.js with the same functionality, so I renamed my app.js to main.js. |
ERROR Failed to compile with 2 errors 13:46:35 These relative modules were not found:
|
Adjusting the serve script in the package.json solved the issue for me too: |
I have same problem and I still could not solve that problem. Npm works well on my local but I use Buildkite for git. When buildkite try to do that, it response like this. Do you have any suggestion for that ?
|
just solved it after 2 hours These dependencies were not found: /Users/newuser/Documents/projects/wheel/ProjectName/node_modules/webpack-dev-server/client/index.js?http://10.0.0.4:8080/sockjs-node in multi ../ProjectName/node_modules/webpack-dev-server/client?http://10.0.0.4:8080/sockjs-node ../ProjectName/node_modules/webpack/hot/dev-server.js ./src/main.js, multi ../ProjectName/node_modules/webpack-dev-server/client?http://localhost ../ProjectName/node_modules/webpack/hot/dev-server.js ../ProjectName/node_modules/webpack-dev-server/client?http://10.0.0.4:8080/sockjs-node ./src/main.js This relative module was not found: ./src/main.js in multi ../ProjectName/node_modules/webpack-dev-server/client?http://10.0.0.4:8080/sockjs-node ../ProjectName/node_modules/webpack/hot/dev-server.js ./src/main.js, multi ../ProjectName/node_modules/webpack-dev-server/client?http://localhost ../ProjectName/node_modules/webpack/hot/dev-server.js ../ProjectName/node_modules/webpack-dev-server/client?http://10.0.0.4:8080/sockjs-node ./src/main.js In order to fix this, I had to change the names of all the folders in my path to not contain any upper case letters and voila, it fixed it Hope this helps :) |
Tive esse problema ao tentar importar um componente que estava em um diretirio a um nivel abaixo do diretotio do componente, resolvi passando o caminho completo do componente , exp do erro:import objeto from "./src/servirces/Objeto" solucção: import objeto from "/home/peog-05linux/Desktop/Tp01SD/frontend/src/servirces/Objeto.js" |
In my case, some VS Code extension had added accidentally an import that i don't need. |
the error instructed to install " npm install --save" this module |
when runing dev-server there throw these two Error
ERROR Failed to compile with 2 errors 10:53:28
These relative modules were not found:
node-version 6.8.0
window10
i don't modify the webpack default config, it can run the app sometime but mostly throw the error
The text was updated successfully, but these errors were encountered: