Skip to content

Tag: node.js

Electron – How to add external files?

I have an Electron app. I try to make the app open an .exe file. I created a directory in the root folder named lib and placed the .exe file there. In development, I have no problem opening the file by using __dirname + ‘/lib/file.exe, but when I package the app (using yarn dist), it does not open the e…

ReferenceError : window is not defined at object. Node.js

I’ve seen similar questions that were asked here but none matches my situation. In my web I have 3 JavaScript files : client.js , server.js ,myModule.js . In client.js I create a window variable called windowVar and I add to it some atrributes. In myModule.js ,I add some other attributes and use them th…

Detect swipe left in React Native

How can I detect a left swipe on the entire screen in React Native? Would it be necessary to use PanResponder or can it be done a little more easy? Answer There is an existing component react-native-swipe-gestures for handling swipe gestures in up, down, left and right direction, see https://github.com/glepur…

Get element height with Vuejs

I want to get the height of a div in order to make the height of another div matching it. I used the method clientHeight, but It doesn’t return me the good value (smaller value). Actually, It seems to return a height before all elements are charged. After some research online, I tried to put a window.lo…