vuex-electron | Integration of Vuex and Electron | State Container library
kandi X-RAY | vuex-electron Summary
kandi X-RAY | vuex-electron Summary
The easiest way to share your Vuex Store between all processes (including main).
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of vuex-electron
vuex-electron Key Features
vuex-electron Examples and Code Snippets
Community Discussions
Trending Discussions on vuex-electron
QUESTION
I can't find the solution to this anywhere.
I have this sample vue-vuex-electron app that I've created and I want to enable / disable some submenus of the app according to whether the vuex state 'isLogged' is true or false. I managed to apply that to the nav router-links (using v-if), but not yet to the menu items... 'cause I don't know how to access the actual Menu (already set and rendered at the main process).
For example, at my Home.vue, I'd like to import the Electron.Menu of the app and set the following:
...ANSWER
Answered 2020-Oct-20 at 01:06OK, nobody knew this one, so I managed to work around it myself... and I'm sharing the solution to help others.
I actually could not find a way to get or manage the Electron Menu at the renderer process, from within the Vue components, so I let it to be updated at the main process itself, where I have access to all Electron components easily.
QUESTION
I have an Electron app on windows and I use the store to determine whether or not a user has completed the program configuration. This is so if they did complete it, the setup page is not displayed when the program is re-opened.
The issue is, when I uninstall the program using the bundled uninstaller and then reinstall it, the program skips the setup page.
I have deleted vuex.json
in C:\Users\\AppData\Roaming\
but that doesn't help. This is index.js
, I would like to keep the persistedState
ANSWER
Answered 2020-Aug-29 at 01:29From the comments:
There's a an Electron
folder in:
C:\Users\\AppData\Roaming\Electron
.
You could delete that whole folder or just vuex.json
or even change the values inside vuex.json
. This only applies to development builds.
If you've already installed the Electron application (i.e. you build the app for a target platform and ran the installer) the directory on Windows would be C:\Users\\AppData\Local\
Don't know where MacOS puts installed things
QUESTION
I'm trying to use the bcrypt-package inside a vue-electron project, but there is an N-api version issue when I try to run it:
...ANSWER
Answered 2020-May-01 at 19:14So I found an answer to my own question in the end:
Electron comes bundled with its own version of nodejs apparently. Updating electron fixed my error.
QUESTION
I have installed the template from Electron-vue and I'm experiencing an issue with specific websites. These websites work on Chrome and Edge, yet, fail to completely load in webview
.
The following example is the whole setup of the view. The console of this show that Local Storage
, Session Storage
and IndexedDB
only have an entry for the website faselhd
but have no data inside. The Cookies
has an entry for the website with this type of data fcuid
ANSWER
Answered 2020-Mar-22 at 15:13You're using the default template electron-vue
which it uses a very old Electron 2.0.1
and that is Chrome 61, Node 8.9.3, V8 6.1.534.41
which is quite outdated to properly support Local Storage
and Session Storage
. You need to update Electron to a newer version.
To your existing project
- Update
electron
to8.1.x
by runningyarn add electron
(this will update electron to latest8.1.1
) - Open
.electron-vue/webpack.renderer.config.js
and at line115
changeHtmlWebpackPlugin
configuration object to this:
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install vuex-electron
Install package with using of yarn or npm: yarn install vuex-electron or npm install vuex-electron
Include plugins in your Vuex store:: import Vue from "vue" import Vuex from "vuex" import { createPersistedState, createSharedMutations } from "vuex-electron" Vue.use(Vuex) export default new Vuex.Store({ // ... plugins: [ createPersistedState(), createSharedMutations() ], // ... })
In case if you enabled createSharedMutations() plugin you need to create an instance of store in the main process. To do it just add this line into your main process (for example src/main.js): import './path/to/your/store'
Well done you did it! The last step is to add the star to this repo :smile:
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page