move vue project unexpected error ...mapActions - node.js

I created a vue project on my local computer then I tried to put it in my work computers (we have a closed server) but then the project does not run properly both the compile (after runing npm run build) and uncompile version.
The error I get in the uncompile version is in a file name app.js "
Uncaught SyntaxError unexpected token ...
" the error in line 27239 the line is this
...Object(vuex_WEBPACK_IMPORTED_MODULE_0__["mapActions"])(['actionName'])
in the compile version i get two errors of "Uncaught SyntaxError
unexpected token ..." in two files chunk-vendors.261c1333.js ,
app.195dacfc.js
after remove the reference to the mapActions this go for the next file and tell me there is a error syntax in any vuex elements mapState ...
I tried to reinstall the project , rebring the project from my computer , check the project in my project (works fine).
tried to install on other computers in my companay.
tried to remove this import from the project but the i am getting another reference to error in the project this time on ...mapState(['stateName'])
...Object(vuex_WEBPACK_IMPORTED_MODULE_0__["mapActions"])(['actionName'])
...mapState(['stateName']) //show error here in this component
I need to find a way to make it posible for vuex to work on my project I think this is the problem.

So i solved the problem. The issue was that my vue cli version was 2.9.6 and not 3.
So i updated the vue cli version then created a new project with the new cli.
Then moved all the fukes to the new project and it's worked.

Related

Uncaught TypeError: Cannot read property 'id' of undefined at registerNgModuleType

I have a problem that when I clone my repository of the app in angular, after installing the node_module and executing the ng serve it throws me this error and I have already looked for a thousand and one answers but none are correct, the app is from angular 8.1 and my angular global is 11 I do not know if it can influence, but it is with the only angular project that happens to me, at times the ng serve lifts the project and it can be seen but I barely make a modification and I give it save this error appears, I need help that advice me give?
enter image description here
I had the same problem.
I solved the problem by disabled the Angular Language Service for that workspace.
I hope this solves your problem
I could find the error, it turns out that VS code as editor every time I ran the npm install and then the ng serve ran perfect, one time I make a modification and give it ctrl + s it bugea my project and when I run the ng serve me again I get the error, so I had to clone my repository again and work with sublime text and it did not give me the error. It must have been some vscode plugin that makes this happen but it is with very few projects.

JHipster - prod build is not working correctly

I worked a lot on my JHipster project. After 3 weeks I packaged the project again and tried to run the war.
The war is running but the problem is that there is a problem with the frontend. It shows the Hipster error "An error has occured :-(...".
The console logs:
Uncaught TypeError: Cannot read property 'concat' of undefined
at Module.503
I'm just confused because when I run npm start, everything works. I didn't change the webpack or package.json. I'm using the newest JH version.
I solved my issue. We are using index files in Angular. The order of the exports was not correct. We exported the module first and the module tried to access data from the index which was not exported at this time.
Hope I could help you.

NodeJS Windows 10 geolocation module throws error in electron when the app starts

I was using module "#nodert-win10-rs4/windows.devices.geolocation" in an electronjs app which was working fine. Later I installed a node module and rebuilt all the modules. Now it stopped working and throwing error. The previous version of that module ( "#nodert-win10-rs4/windows.devices.geolocation") was 1.0.0, Thus I reinstalled it, new version of the module is "0.3.2" but still error. Even i tried this in fresh new electron quick start app and I see the same error. I'm adding here the screenshot of the package.json and the error. (FYI - The module is installed and rebuilt without any error although it has some warning, I've added a screenshot of the installation/built too). Really appreciate any help/suggestions.
I saw other posts with similar errors but I already took the actions mentioned there.
Thanks
Musa
N.B - Cross posted here
I ran into the same issue and here is how I resolved it.
Copy the windows.devices.geolocation into your electron app folder and update the dependencies to point to the location of the folder. You need to this line added to your package.json of your Electron App
"windows.devices.geolocation": "file:windows.devices.geolocation"
Navigate to the newly copied folder and build your NodeRT "addon" to match your Electron version. See this post here NodeRT with Electron
node-gyp rebuild --target=4.0.1 --arch=x64 --dist-url=https://atom.io/download/atom-shell
Run npm install at the the top level Electron app.

Exception could not locate binding file after updating electron version

I'm working on updating my project from using electron version 1.2.5
to the newest electron at this time which is 1.7.7 (atleast it was when I downloaded it). My node version 6.9.1.
I've encountered a problem when I start my project with this new electron version,
the error in general is about "could not locate the binding files. and it mostly regards the async module.
There is also some part of the exception regarding node-etcd module which I use in my project (version 5.0.3)
I found some information about this type of exception online but most of them says stuffs about rebuilding some node module using some npm commands which I didn't quiet understand. I tried to install async module again in a new folder and replace it (with its deps) in the node modules folder im currently using for my project, but I still got the same error.
I'm working in an offline enviorment where I can't take my project "out" to a computer with internet access, I can only bring things from the web to my project (like installing in some folder and then copying that into my project) so any npm or other commands that require web connection are not available to me directly on my work computer. (I can only use them in a different computer and copy the results to a flash drive and bring them to th
Here's 2 pictures of the error (sorry about the quality, its the best I could get):
First part of error
Second part of error
The solution that fixed the problem in my case was going into node_modules - > deasync - > index.js
Before line 31 I added a newline (next to the binding line)
and wrote:
modPath = __dirname;
This solution is hacky, it was accually ly found by an associate a while back, so I am not sure why it works, it might be an issue in deasync, but it fixed the problem.

Node can't start app due to missing module

I have an application that I am running for the first time in a new computer. I keep getting the following error when starting the app
Error: Cannot find module './src/async'
I checked the application directory and I see the module there. I have tried re-installing the module and doing npm install and still no luck.

Resources